<!--工序作业指导书管理-->
<!--用户权限说明-->
<!--管理员：代码：1:可以做所有的操作；
               2:可以添加作业指导书以及所有修改作业指导书的权限；
               3：只能编辑作业指导书，但是不能新加
               4：可以编辑作业指导书，但是不能编辑关联控制计划
               5：只能编审批会签，但是不能修改
               6：只能查看，不能编辑-->
<template>
  <div style="margin: 0;padding: 0">
    <el-container>
      <!--页面表头设计-->
      <el-header style="height: 7vh">
        <el-link class="headMain" href="http://10.255.96.48:3404/">{{main.qualityManagementSystem}}</el-link>
        <span class="center-text">{{main.operationWorkInstruction}}</span>
        <el-popover
            placement="top-start"
            title="用户信息"
            width="200"
            trigger="hover">
          <div style="margin-top: 10px">Name：{{useName}}</div>
          <div style="margin-top: 10px">ID:{{useId}}</div>
          <div style="margin-top: 10px" @click="logOut"><el-link>退出</el-link></div>
          <div class="headMain" slot="reference">{{useName}}</div>
        </el-popover>
      </el-header>
      <el-container>
        <el-aside width="200px">
          <div style="margin-bottom: 10px">
            <el-card class="box-card">
              <div slot="header" class="clearfix" style="text-align: left">
                <span>{{main.selectionPrompt}}</span>
              </div>
              <div style="text-align: left">
                <div style="color: red;font-size: 16px" ><strong>{{main.titleMianId}}</strong></div>
                <div style="color: red;font-size: 16px" ><strong>{{main.titleMianOp}}</strong></div>
              </div>
            </el-card>
          </div>
          <el-input
              :placeholder="main.filter"
              v-model="filterText"
              style="width: 160px">
          </el-input>
          <el-tree
              style="margin: 10px 8px;"
              :data="treeList"
              :props="defaultProps"
              @node-click="treeClick"
              :filter-node-method="filterNode"
              ref="tree"
              highlight-current></el-tree>
        </el-aside>
        <el-container>
          <!--主题设计-->
          <el-main style="overflow-y: auto;overflow-x: auto; height: 79vh">
            <div style="display: flex;height: 75vh;margin-top: 10px">
              <div style="width: 220px; border: 1px solid blue; box-sizing: border-box;overflow-y: auto">
                <div style="margin-top: 10px;text-align: center">
                  <span style="color: red;font-size: 18px">{{main.information}}</span>
                  <div v-if="usePower===1 || usePower==='1'">
                    <el-link style="margin-left: 10px" @click="editTable(1)"><i class="el-icon-circle-plus-outline"></i></el-link>
                    <el-link style="margin-left: 10px" @click="editTable(2)"><i class="el-icon-edit"></i></el-link>
                    <el-link style="margin-left: 10px" @click="editTable(3)"><i class="el-icon-delete"></i></el-link>
                  </div>
                  <hr>
                </div>
                <div style="margin: 8px;text-align: left">
                  <span v-if="tableDataTemp.lineName===''"></span>
                  <span v-else-if="languageS==='chinese'">{{main.line}}{{tableDataTemp.lineName.split('/')[0]}}</span>
                  <span v-else-if="languageS==='english'">{{main.line}}{{tableDataTemp.lineName.split('/')[1]}}</span>
                  <span v-else-if="languageS==='russian'">{{main.line}}{{tableDataTemp.lineName.split('/')[2]}}</span>
                  <hr>
                </div>
                <div style="margin:8px;text-align: left">
                  <span>{{main.op}}{{tableDataTemp.op}}</span>
                  <hr>
                </div>
                <div style="margin:8px;width: 150px">
                  <div v-if="tableDataTemp.fileName===''"></div>
                  <div style="color: #0269fa;font-size: 18px;white-space: normal; overflow-wrap: break-word;"
                       v-else-if="languageS==='chinese' && tableDataTemp.fileName.split('|*|').length===3">{{tableDataTemp.fileName.split('|*|')[0]}}</div>
                  <div style="color: #0269fa;font-size: 18px;white-space: normal; overflow-wrap: break-word;"
                       v-else-if="languageS==='english' && tableDataTemp.fileName.split('|*|').length===3">{{tableDataTemp.fileName.split('|*|')[1]}}</div>
                  <div style="color: #0269fa;font-size: 18px;white-space: normal; overflow-wrap: break-word;"
                       v-else-if="languageS==='russian' && tableDataTemp.fileName.split('|*|').length===3">{{tableDataTemp.fileName.split('|*|')[2]}}</div>
                  <div style="color: #0269fa;font-size: 18px;white-space: normal; overflow-wrap: break-word;"
                       v-else>{{tableDataTemp.fileName}}</div>
                  <hr>
                </div>
                <div style="margin: 8px;text-align: left">
                  <span>{{main.verNoLatest}}</span>
                  <hr>
                </div>
                <div style="margin: 8px;text-align: left">
                  <span >{{main.dateOfPreparation}}</span>
                  <span>{{tableDataTemp.writeDate}}</span>
                  <hr>
                </div>
                <div style="margin: 8px;text-align: left">
                  <span>{{main.implementationDate}}</span>
                  <span>{{tableDataTemp.executeDate}}</span>
                  <hr>
                </div>
                <div style="margin: 8px;text-align: left">
                  <span>{{main.documentNo}}</span>
                  <span>{{tableDataTemp.fileNum}}</span>
                  <hr>
                </div>
                <div style="margin: 8px;text-align: left">
                  <span>{{main.preparedBy}}</span>
                  <span>{{tableDataTemp.writeUse}}</span>
                  <hr>
                </div>
                <div style="margin: 8px;text-align: left">
                  <span>{{main.checked}}</span>
                  <span @click="ratifyClick(1)" >{{tableDataTemp.examineUse}}</span>
                  <hr>
                </div>
                <div style="margin: 8px;text-align: left">
                  <span>{{main.approve}}</span>
                  <span @click="ratifyClick(2)">{{tableDataTemp.ratifyUse}}</span>
                  <hr>
                </div>
                <div style="margin: 8px;text-align: left">
                  <span>{{main.countersigned}}</span>
                  <span @click="ratifyClick(3)">{{tableDataTemp.countersignUse}}</span>
                  <hr>
                </div>
              </div>
              <div style="flex-grow: 1;
                  border: 1px solid blue;
                  box-sizing: border-box;
                  margin-left: 8px;
                  padding: 8px;
                  display: flex;
                  width: 100%">
                <div style="flex: 1;height: 73vh;scroll-margin-right: 8px;overflow-x: auto;border: 1px solid #d3d3d3; /* 修改为浅灰色 */">
                  <div style="text-align: left; margin-top: 4px">
                    <el-link :style="{marginRight:'5px',backgroundColor:workBookHeard1 , color:workBookHeardColour1, padding: '4px 10px', borderRadius: '5px' }"
                              @click="workBookHeard(1)" style="margin-left: 8px">{{pageVal.instruction}}</el-link>
                    <span>|</span>
                    <el-link :style="{marginRight:'5px',backgroundColor:workBookHeard2 , color:workBookHeardColour2, padding: '4px 10px', borderRadius: '5px' }"
                             @click="workBookHeard(2)">{{pageVal.partDetailsList}}</el-link>
                    <span>|</span>
                    <el-link :style="{marginRight:'5px',backgroundColor:workBookHeard3 , color:workBookHeardColour3, padding: '4px 10px', borderRadius: '5px' }"
                             @click="workBookHeard(3)">{{pageVal.failureCase}}</el-link>
                    <span>|</span>
                    <el-link :style="{marginRight:'5px',backgroundColor:workBookHeard4 , color:workBookHeardColour4, padding: '4px 10px', borderRadius: '5px' }"
                             @click="workBookHeard(4)">{{pageVal.manHour}}</el-link>
                    <span>|</span>
                    <el-link :style="{marginRight:'5px',backgroundColor:workBookHeard5 , color:workBookHeardColour5, padding: '4px 10px', borderRadius: '5px' }"
                             @click="workBookHeard(5)">{{pageVal.operator}}</el-link>
                  </div>
                  <hr>
                  <div v-if="workBookHeardUse===1">
                    <el-table
                        :data="workBook"
                        border
                        style="width: 100%;margin-top: 5px"
                        height="66vh"
                        highlight-current-row
                        @expand-change="workBookRowClick">
                      <el-table-column
                          type="expand"
                          v-slot:default="props">
                        <div>
                          <div style="margin-right: 10px;margin-left: 15px;margin-bottom:8px;border: 1px solid blue;padding: 5px">
                            <span>{{pageVal.attentionPointsExplanation}}</span>
                            <span v-if="languageS==='chinese' && props.row.problem.split('|*|').length===3" v-html="props.row.problem.split('|*|')[0]"></span>
                            <span v-else-if="languageS==='english' && props.row.problem.split('|*|').length===3" v-html="props.row.problem.split('|*|')[1]"></span>
                            <span v-else-if="languageS==='russian' && props.row.problem.split('|*|').length===3" v-html="props.row.problem.split('|*|')[2]"></span>
                            <span v-else>{{props.row.problem}}</span>
                          </div>
                          <div style="margin-right: 10px;margin-left: 15px;margin-bottom:8px;border: 1px solid blue;padding: 5px">
                            <span>{{pageVal.qualityInspection}}</span>
                            <span v-if="languageS==='chinese' && props.row.inspect.split('|*|').length===3" v-html="props.row.inspect.split('|*|')[0]"></span>
                            <span v-else-if="languageS==='english' && props.row.inspect.split('|*|').length===3" v-html="props.row.inspect.split('|*|')[1]"></span>
                            <span v-else-if="languageS==='russian' && props.row.inspect.split('|*|').length===3" v-html="props.row.inspect.split('|*|')[2]"></span>
                            <span v-else>{{props.row.inspect}}</span>
                          </div>
                          <div style="margin-right: 10px;margin-left: 15px;margin-bottom:8px;border: 1px solid blue;padding: 5px">
                            <div>{{pageVal.controlPlanRequirements}}<el-link @click="editBook(6,props)" v-if="usePower===1 || usePower==='1'"><i class="el-icon-edit"></i></el-link></div>
                            <hr>
                            <div style="width: 100%;" v-if="isControlPlanLoad">
                              <el-table
                                  :data="controlPlanData"
                                  style="width: 100%"
                                  size="mediut">
                                <el-table-column
                                    :label="pageVal.tolerance"
                                    width="250px"
                                    prop="specification"
                                    fixed
                                    v-slot:default="scope">
                                  <span v-if="languageS==='chinese'">{{scope.row.specification}}</span>
                                  <span v-if="languageS==='english'">{{scope.row.specification_english}}</span>
                                  <span v-if="languageS==='russian'">{{scope.row.specification_russian}}</span>
                                </el-table-column>
                                <el-table-column
                                    :label="pageVal.measure"
                                    width="100px"
                                    prop="measure"
                                    v-slot:default="scope">
                                  <span v-if="languageS==='chinese'">{{scope.row.measure}}</span>
                                  <span v-if="languageS==='english'">{{scope.row.measure_english}}</span>
                                  <span v-if="languageS==='russian'">{{scope.row.measure_russian}}</span>
                                </el-table-column>
                                <el-table-column
                                    :label="pageVal.capacity"
                                    width="100px"
                                    prop="capacity"
                                    v-slot:default="scope">
                                  <span v-if="languageS==='chinese'">{{scope.row.capacity}}</span>
                                  <span v-if="languageS==='english'">{{scope.row.capacity_english}}</span>
                                  <span v-if="languageS==='russian'">{{scope.row.capacity_russian}}</span>
                                </el-table-column>
                                <el-table-column
                                    :label="pageVal.frequency"
                                    width="100px"
                                    prop="frequency"
                                    v-slot:default="scope">
                                  <span v-if="languageS==='chinese'">{{scope.row.frequency}}</span>
                                  <span v-if="languageS==='english'">{{scope.row.frequency_english}}</span>
                                  <span v-if="languageS==='russian'">{{scope.row.frequency_russian}}</span>
                                </el-table-column>
                                <el-table-column
                                    :label="pageVal.controlMethod"
                                    width="100px"
                                    prop="method"></el-table-column>
                                <el-table-column
                                    label="操作"
                                    width="50"
                                    align="center"
                                    v-slot:default="scope">
                                  <el-link @click="deleteData('deleteControlPlan',scope)">
                                    <i class="el-icon-delete"></i>
                                  </el-link>
                                </el-table-column>
                              </el-table>
                            </div>
                          </div>
                          <div style="margin-right: 10px;margin-left: 15px;margin-bottom:8px;border: 1px solid blue;padding: 5px">
                            <span>{{pageVal.tools}}</span>
                            <span v-if="languageS==='chinese' && props.row.toll.split('|*|').length===3">{{props.row.toll.split('|*|')[0]}}</span>
                            <span v-else-if="languageS==='english' && props.row.toll.split('|*|').length===3">{{props.row.toll.split('|*|')[1]}}</span>
                            <span v-else-if="languageS==='russian' && props.row.toll.split('|*|').length===3">{{props.row.toll.split('|*|')[2]}}</span>
                            <span v-else>{{props.row.toll}}</span>
                          </div>
                          <div style="margin-right: 10px;margin-left: 15px;margin-bottom:8px;border: 1px solid blue;padding: 5px">
                            <span>{{pageVal.equipment}}</span>
                            <span v-if="languageS==='chinese' && props.row.device.split('|*|').length===3">{{props.row.device.split('|*|')[0]}}</span>
                            <span v-else-if="languageS==='english' && props.row.device.split('|*|').length===3">{{props.row.device.split('|*|')[1]}}</span>
                            <span v-else-if="languageS==='russian' && props.row.device.split('|*|').length===3">{{props.row.device.split('|*|')[2]}}</span>
                            <span v-else>{{props.row.device}}</span>
                          </div>
                          <div style="margin-right: 10px;margin-left: 15px;margin-bottom:8px;border: 1px solid blue;padding: 5px">
                            <span>{{pageVal.accessories}}</span>
                            <span v-if="languageS==='chinese' && props.row.accessories.split('|*|').length===3">{{props.row.accessories.split('|*|')[0]}}</span>
                            <span v-else-if="languageS==='english' && props.row.accessories.split('|*|').length===3">{{props.row.accessories.split('|*|')[1]}}</span>
                            <span v-else-if="languageS==='russian' && props.row.accessories.split('|*|').length===3">{{props.row.accessories.split('|*|')[2]}}</span>
                            <span v-else>{{props.row.accessories}}</span>
                          </div>
                          <div style="margin-right: 10px;margin-left: 15px;margin-bottom:8px;border: 1px solid blue;padding: 5px">
                            <span style="margin-right: 30px">{{pageVal.startingSignal}}{{props.row.startSignal}}</span>
                            <span>{{pageVal.endSignal}}{{props.row.endSignal}}</span>
                          </div>
                        </div>
                      </el-table-column>
                      <el-table-column
                          v-slot:default="scope"
                          :label="pageVal.order"
                          width="50">
                        {{scope.$index+1}}
                      </el-table-column>
                      <el-table-column
                          prop="work"
                          :label="pageVal.stepContent"
                          v-slot:default="scope">
                        <div>
                          <span @click="editBook(100,scope)" v-if="languageS==='chinese' && scope.row.work.split('|*|').length===3">{{scope.row.work.split('|*|')[0]}}</span>
                          <span @click="editBook(100,scope)" v-else-if="languageS==='english' && scope.row.work.split('|*|').length===3">{{scope.row.work.split('|*|')[1]}}</span>
                          <span @click="editBook(100,scope)" v-else-if="languageS==='russian' && scope.row.work.split('|*|').length===3">{{scope.row.work.split('|*|')[2]}}</span>
                          <span @click="editBook(100,scope)" v-else>{{scope.row.work}}</span>
                          <span @click="editBook(100,scope)">--{{scope.row.spendTime}}S</span>
                          <template v-if="usePower===1 || usePower==='1'">
                            <el-link style="margin-left: 20px" @click="editBook(2,scope)"><i class="el-icon-download"></i></el-link>
                            <el-link style="margin-left: 10px" @click="editBook(7,scope)"><i class="el-icon-upload2"></i></el-link>
                            <el-link style="margin-left: 10px" @click="editBook(1,scope)"><i class="el-icon-edit"></i></el-link>
                            <el-link style="margin-left: 10px" @click="editBook(4,scope)"><i class="el-icon-picture-outline"></i></el-link>
                            <el-link style="margin-left: 10px" @click="editBook(5,scope)"><i class="el-icon-video-camera"></i></el-link>
                            <el-link style="margin-left: 10px" @click="editBook(3,scope)"><i class="el-icon-delete"></i></el-link>
                          </template>
                        </div>
                      </el-table-column>
                    </el-table>
                  </div>
                  <div v-else-if="workBookHeardUse===2">
                    <div style="text-align: right" v-if="usePower===1 || usePower==='1'">
                      <el-link style="color: red" v-if="partsListData.length===0" @click="editPartsList(5,null)" >{{pageVal.add}}</el-link>
                    </div>
                    <el-table
                        :data="partsListData"
                        border
                        style="width: 100%;margin-top: 5px"
                        height="65vh"
                        highlight-current-row
                        @row-click="partsListClick">
                      <el-table-column
                          type="expand"
                          v-slot:default="props">
                        <div>
                          <div style="margin-right: 10px;margin-left: 15px;margin-bottom:8px;border: 1px solid blue;padding: 5px">
                            <span>{{pageVal.specialCharacteristics1}}</span>
                            <span>{{props.row.special}}</span>
                            <div>
                              <span>{{pageVal.selfCheckingProjects}}</span>
                              <el-table
                                  :data="partCheckListData"
                                  border
                                  style="width: 100%;margin-top: 5px"
                                  height="25vh"
                                  highlight-current-row>
                                <el-table-column
                                    :label="pageVal.order"
                                    width="70px">
                                </el-table-column>
                                <el-table-column
                                    prop="project"
                                    :label="pageVal.project">
                                </el-table-column>
                                <el-table-column
                                    prop="requirement"
                                    :label="pageVal.requirement">
                                </el-table-column>
                                <el-table-column
                                    :label="pageVal.edit">
                                  <el-link><i class="el-icon-download"></i></el-link>
                                  <el-link><i class="el-icon-edit"></i></el-link>
                                  <el-link><i class="el-icon-edit"></i></el-link>
                                </el-table-column>
                              </el-table>
                            </div>
                          </div>
                        </div>
                      </el-table-column>
                      <el-table-column
                          v-slot:default="scope"
                          :label="pageVal.diagramCode"
                          width="50">
                        {{scope.row.mapId}}
                      </el-table-column>
                      <el-table-column
                          prop="stepNum"
                          width="50"
                          :label="pageVal.stepNumber">
                      </el-table-column>
                      <el-table-column
                          prop="partName"
                          :label="pageVal.partName"
                          width="120"
                          v-slot:default="scope">
                        <span v-if="scope.row.partName.split('/').length>3 && languageS==='chinese'">
                          {{scope.row.partName.split('/')[1]}}
                        </span>
                        <span v-else-if="scope.row.partName.split('/').length>3 && languageS==='english'">
                          {{scope.row.partName.split('/')[2]}}
                        </span>
                        <span v-else-if="scope.row.partName.split('/').length>3 && languageS==='russian'">
                          {{scope.row.partName.split('/')[3]}}
                        </span>
                        <span v-else-if="scope.row.partName.split('|*|').length>3 && languageS==='chinese'">
                          {{scope.row.partName.split('|*|')[0]}}
                        </span>
                        <span v-else-if="scope.row.partName.split('|*|').length>3 && languageS==='english'">
                          {{scope.row.partName.split('|*|')[1]}}
                        </span>
                        <span v-else-if="scope.row.partName.split('|*|').length>3 && languageS==='russian'">
                          {{scope.row.partName.split('|*|')[2]}}
                        </span>
                        <span v-else>
                          {{scope.row.partName}}
                        </span>
                      </el-table-column>
                      <el-table-column
                          prop="partId"
                          :label="pageVal.partNumber"
                          v-slot:default="scope">
                        <span v-if="scope.row.partName.split('/').length>3">
                          {{scope.row.partName.split('/')[0]}}
                        </span>
                      </el-table-column>
                      <el-table-column
                          prop="partNum"
                          :label="pageVal.quantity"
                          width="50">
                      </el-table-column>
                      <el-table-column
                          :label="pageVal.edit"
                          v-slot:default="scope" v-if="usePower===1 || usePower==='1'">
                        <div>
                          <el-link style="margin-left: 5px" @click="editPartsList(1,scope)"><i class="el-icon-edit"></i></el-link>
                          <el-link style="margin-left: 10px" @click="editPartsList(2,scope)"><i class="el-icon-download"></i></el-link>
                          <el-link style="margin-left: 10px" @click="editPartsList(4,scope)"><i class="el-icon-picture-outline"></i></el-link>
                          <el-link style="margin-left: 10px" @click="editPartsList(3,scope)"><i class="el-icon-delete"></i></el-link>
                        </div>

                      </el-table-column>
                    </el-table>
                  </div>
                  <div v-else-if="workBookHeardUse===3">
                    <div v-if="usePower===1 && caseUseData.length===0">
                      <el-link @click="caseUseShow(1,null)">{{pageVal.add}}</el-link></div>
                    <div>
                      <el-table
                          :data="caseUseData"
                          border
                          style="width: 100%">
                        <el-table-column
                            prop="id"
                            :label="pageVal.order"
                            width="50"
                            v-slot:default="scope">
                          <span>{{scope.row.id+1}}</span>
                          <template v-if="usePower===1 || usePower==='1'">
                            <el-link @click="caseUseShow(6,scope)"><i class="el-icon-download"></i></el-link>
                          </template>
                        </el-table-column>
                        <el-table-column
                            prop="caseUse"
                            :label="pageVal.caseDescription"
                            v-slot:default="scope">
                          <span>{{scope.row.caseUse}}</span>
                          <template v-if="usePower===1 || usePower==='1' || caseUseData.length>0">
                            <el-link style="margin-left: 20px" @click="caseUseShow(2,scope)"><i class="el-icon-edit"></i></el-link>
                            <el-link style="margin-left: 10px" @click="caseUseShow(4,scope)"><i class="el-icon-picture-outline"></i></el-link>
                            <el-link style="margin-left: 10px" @click="caseUseShow(5,scope)"><i class="el-icon-video-camera"></i></el-link>
                            <el-link style="margin-left: 10px" @click="caseUseShow(3,scope)"><i class="el-icon-delete"></i></el-link>
                          </template>
                        </el-table-column>
                      </el-table>
                    </div>
                  </div>
                  <div v-else-if="workBookHeardUse===4" ref="myChartBor" style="height: 66vh;width:35vw">
                  </div>
                  <div v-else-if="workBookHeardUse===5">
                    <div style="margin-bottom: 5px;text-align: right">
                      <el-link @click="operatorListEditShow(1,null)" style="margin-right: 5px"><i class="el-icon-download"></i></el-link>
                    </div>
                    <el-table
                        :data="operatorList"
                        border
                        style="width: 100%"
                        height="65vh"
                        @row-click="operatorRowClick">
                      <el-table-column
                          type="expand"
                          v-slot:default="props">
                        <div>
                          <div>
                            <span>指导人：</span><span>{{props.row.mentor}}</span>
                          </div>
                          <div>
                            <span>等级：</span><span>{{props.row.skill_level}}</span>
                          </div>
                        </div>
                      </el-table-column>
                      <el-table-column
                          :label="pageVal.order"
                          prop="id"
                          width="50">
                      </el-table-column>
                      <el-table-column
                          prop="operator_id"
                          :label="pageVal.employeeId">
                      </el-table-column>
                      <el-table-column
                          prop="operator_name"
                          :label="pageVal.name">
                      </el-table-column>
                      <el-table-column
                          prop="star_time"
                          :label="pageVal.startDate">
                      </el-table-column>
                      <el-table-column
                          :label="pageVal.edit"
                          v-slot:default="scope">
                        <el-link @click="operatorListEditShow(2,scope)" style="margin-right: 5px"><i class="el-icon-edit"></i></el-link>
                        <el-link @click="deleteData('operatorRowDeleteData',scope)" style="margin-right: 5px"><i class="el-icon-delete"></i></el-link>
                      </el-table-column>
                    </el-table>
                  </div>
                </div>
                <div style="flex: 1;height: 73vh;overflow-x: auto;border: 1px solid #d3d3d3; /* 修改为浅灰色 */" >
                  <div style="width: 100%;height: 62vh;text-align: left;">
                    <el-link :style="{ backgroundColor:videoAndImage1 , color:videoAndImageColor1 , padding: '4px 10px', borderRadius: '5px' }"
                             @click="videoAndImage(1)" style="margin-left: 8px;margin-top: 4px">{{main.picture}}</el-link>
                    <el-link style="margin-left: 8px;margin-right: 8px;margin-top: 4px">|</el-link>
                    <el-link :style="{ backgroundColor:videoAndImage2 , color:videoAndImageColor2 , padding: '4px 10px', borderRadius: '5px' }" style="margin-top: 4px"
                             @click="videoAndImage(2)">{{main.video}}</el-link>
                    <hr>
                    <div class="block">
                      <el-carousel trigger="click" height="62vh" v-if="editVideoAndImageUse===1">
                        <el-carousel-item v-for="(item, index) in itemView" :key="index">
                          <el-image
                              style="width: 100%; height: 100%"
                              :src="item"
                              fit='contain'
                              @click="handleImageClick(item)">
                          </el-image>
                        </el-carousel-item>
                      </el-carousel>
                      <el-carousel trigger="click" height="62vh" :autoplay="false" v-if="editVideoAndImageUse===2">
                        <el-carousel-item v-for="(item, index) in itemViewVideo" :key="index">
                          <video
                              style="width: 100%; height: 100%"
                              :src="item"
                              controls></video>
                        </el-carousel-item>
                      </el-carousel>
                    </div>
                  </div>
                </div>
              </div>
            </div>
          </el-main>
          <el-footer>
            <el-button plain size="small" @click="chooseLanguage('chinese')">中  文</el-button>
            <el-button plain size="small" @click="chooseLanguage('russian')">Русский язык</el-button>
            <el-button plain size="small" @click="chooseLanguage('english')">English</el-button>
          </el-footer>
        </el-container>
      </el-container>
    </el-container>

    <!--弹窗放置区-->
    <!--删除提醒的弹窗-->
    <el-dialog
        :title="titleUse"
        :visible.sync="deleteDialog"
        width="400px"
        :before-close="handleClose">
      <span>{{main.sureToDelete}}</span>
      <span slot="footer" class="dialog-footer">
        <el-button @click="deleteDialog = false" size="mini">{{main.cancel}}</el-button>
        <el-button type="primary" size="mini" @click="deleteDataOk">{{main.ok}}</el-button>
      </span>
    </el-dialog>
    <!--作业指导书表头编辑的弹窗-->
    <el-dialog
        :title="titleUse"
        :visible.sync="dialogTableHeader"
        width="30%"
        :before-close="handleClose">
      <el-form ref="formTableData" status-icon :rules="rulesForm" :model="formTableData" label-width="80px">
        <el-form-item :label="pageVal.workshop" prop="workshop">
          <el-select v-model="formTableData.workshop" :placeholder="pageVal.select" disabled style="width: 100%" @change="(val) => selectChange(val)">
            <el-option
                v-for="item in optionWorkshop"
                :key="item.value"
                :label="item.label"
                :value="item.value">
            </el-option>
          </el-select>
        </el-form-item>
        <el-form-item :label="pageVal.drawingNumber" prop="workshop">
          <el-input v-model="formTableData.productId" disabled></el-input>
        </el-form-item>
        <el-form-item :label="pageVal.line" prop="lineName">
          <el-select
              v-model="formTableData.lineName"
              :placeholder="pageVal.select"
              style="width: 100%"
              :disabled="disabledLineName">
            <el-option
                v-for="item in optionLine"
                :key="item.value"
                :label="item.label"
                :value="item.value">
            </el-option>
          </el-select>
        </el-form-item>
        <div style="display: flex; /* 启用 Flexbox 布局 */justify-content: space-between; /* 子元素之间的间隔平均分布 */  ">
          <el-form-item :label="pageVal.op" style="flex:1" prop="op">
            <el-select
                v-model="formTableData.op"
                :placeholder="pageVal.select"
                style="width: 100%"
                disabled>
              <el-option
                  v-for="item in optionOp"
                  :key="item.value"
                  :label="item.label"
                  :value="item.value">
              </el-option>
            </el-select>
          </el-form-item>
          <el-form-item  :label="pageVal.verNo" style="flex:1" prop="editionNum">
            <el-select
                v-model="formTableData.editionNum"
                :placeholder="pageVal.select"
                style="width: 100%">
              <el-option
                  v-for="item in optionEditionNum"
                  :key="item.value"
                  :label="item.label"
                  :value="item.value">
              </el-option>
            </el-select>
          </el-form-item>
        </div>
        <el-form-item :label="pageVal.fileName" prop="fileName">
          <el-input
              type="textarea"
              :rows="2"
              :placeholder="pageVal.separate"
              v-model="formTableData.fileName">
          </el-input>
        </el-form-item>
        <el-form-item :label="pageVal.dateOfPreparation" prop="writeDate">
          <el-date-picker
              v-model="formTableData.writeDate"
              type="date"
              :placeholder="pageVal.selectTheDate"
              style="width: 100%">
          </el-date-picker>
        </el-form-item>
        <el-form-item :label="pageVal.implementationDate" prop="executeDate">
          <el-date-picker
              v-model="formTableData.executeDate"
              type="date"
              :placeholder="pageVal.selectTheDate"
              style="width: 100%">
          </el-date-picker>
        </el-form-item>
        <div style="font-size: 18px;color: #0269fa;margin-bottom: 10px">{{pageVal.designateRelevantPersonnel}}</div>
        <div style="display: flex; /* 启用 Flexbox 布局 */justify-content: space-between; /* 子元素之间的间隔平均分布 */  ">
          <el-form-item :label="pageVal.preparedBy" style="flex:1" prop="writeUse">
            <el-input  :placeholder="useName" disabled="disabled"></el-input>
          </el-form-item>
          <el-form-item  :label="pageVal.checked" style="flex:1" prop="examineUse">
            <el-input v-model="formTableData.examineUse" :placeholder="pageVal.enter"></el-input>
          </el-form-item>
        </div>
        <div style="display: flex; /* 启用 Flexbox 布局 */justify-content: space-between; /* 子元素之间的间隔平均分布 */  ">
          <el-form-item :label="pageVal.countersigned" style="flex:1" prop="countersignUse">
            <el-input v-model="formTableData.countersignUse" :placeholder="pageVal.enter"></el-input>
          </el-form-item>
          <el-form-item  :label="pageVal.approve" style="flex:1" prop="ratifyUse">
            <el-input v-model="formTableData.ratifyUse" :placeholder="pageVal.enter"></el-input>
          </el-form-item>
        </div>
        <el-form-item>
          <el-button type="primary" @click="callExisting" size="small">{{pageVal.invokeExisting}}</el-button>
          <el-button type="primary" @click="onSubmit(editTableUse,'formTableData')" size="small">{{pageVal.create}}</el-button>
          <el-button @click="dialogTableHeader=false" size="small">{{pageVal.cancel}}</el-button>
        </el-form-item>
      </el-form>
    </el-dialog>
    <!--零部件列表编辑的弹窗-->
    <el-dialog
        :title="titleUse"
        :visible.sync="partsListDialog"
        width="600px"
        :before-close="handleClose">
      <el-form ref="partsListFrom" status-icon :model="partsListFrom" label-width="80px">
        <el-form-item :label="pageVal.partName1">
          <el-select v-model="partsListFrom.partName" filterable :placeholder="pageVal.select" style="width: 100%">
            <el-option
                v-for="item in partsListOptions"
                :key="item.value"
                :label="item.label"
                :value="item.value">
            </el-option>
          </el-select>
        </el-form-item>
        <el-form-item :label="pageVal.assemblyQuantity">
          <el-input-number style="width: 100%" v-model="partsListFrom.partNum" :aria-placeholder="pageVal.enterQuantity"></el-input-number>
        </el-form-item>
        <el-form-item :label="pageVal.additionalInformation" prop="workshop">
          <el-input v-model="partsListFrom.mapId" :placeholder="pageVal.diagramCode" style="width: 150px;margin-right: 15px"></el-input>
          <el-input v-model="partsListFrom.stepNum" :placeholder="pageVal.stepNumber" style="width: 150px;margin-right: 15px"></el-input>
          <el-input v-model="partsListFrom.special" :placeholder="pageVal.specialCharacteristics" style="width: 150px;"></el-input>
        </el-form-item>
        <el-form-item>
          <el-button type="primary" @click="partsListEditClick">{{pageVal.create}}</el-button>
          <el-button @click="partsListDialog=false">{{main.cancel}}</el-button>
        </el-form-item>
      </el-form>
    </el-dialog>

    <!--输入多个文本的弹窗类型-->
    <el-dialog
        :title="titleUse"
        :visible.sync="dialogVisibleText"
        width="50%"
        :before-close="handleClose">
      <div v-loading="work_problem_loading">
        <div style="text-align: left">
          <div style="overflow: hidden;">
            <div style="float: left; width: 45%; text-align: left;">
              <span style="font-size: 18px;color: red">{{pageVal.operationStep}}</span>
            </div>
            <div style="float: right; width: 45%; text-align: right;">
              <span>{{pageVal.workTime}}</span><el-input-number v-model="inputNum" :min="0" :max="200"></el-input-number>
            </div>
          </div>
          <div>
            <el-tabs v-model="pointsActiveTab" type="card">
              <el-tab-pane :label="main.chinese" name="chinese">
                <el-input :placeholder="pageVal.enter"
                          v-model="inputText1"
                          style="width: 100%;margin-top: 8px"
                          type="textarea"
                          :rows="3"></el-input>
              </el-tab-pane>
              <el-tab-pane :label="main.english" name="english">
                <el-input :placeholder="pageVal.enter"
                          v-model="inputTextEnglish1"
                          style="width: 100%;margin-top: 8px"
                          type="textarea"
                          :rows="3"></el-input>
              </el-tab-pane>
              <el-tab-pane :label="main.russian" name="russian">
                <el-input :placeholder="pageVal.enter"
                          v-model="inputTextRussian1"
                          style="width: 100%;margin-top: 8px"
                          type="textarea"
                          class="russian-input"
                          :rows="3"></el-input>
              </el-tab-pane>
            </el-tabs>
          </div>
          <div style="margin-top: 10px;text-align: right">
            <el-button @click="translate(2)">自动翻译|Automatic Translation|Автоматический перевод</el-button>
          </div>
          <div ref="editorContainer" style="text-align: left;margin-bottom:10px;"></div>
        </div>
        <!-- 关注点富文本编辑器（中/英/俄） -->
        <div style="margin-top: 10px;text-align: left">
          <span style="font-size: 18px">{{pageVal.focusPoint}}</span>
          <div>
            <el-tabs v-model="pointsActiveTab" type="card" style="margin-top: 8px">
              <el-tab-pane :label="main.chinese" name="chinese">
                <div ref="pointsChineseEditor" class="editor-container"></div>
              </el-tab-pane>
              <el-tab-pane :label="main.english" name="english">
                <div ref="pointsEnglishEditor" class="editor-container"></div>
              </el-tab-pane>
              <el-tab-pane :label="main.russian" name="russian">
                <div ref="pointsRussianEditor" class="editor-container"></div>
              </el-tab-pane>
            </el-tabs>
          </div>
          <div>
            <div style="margin-top: 10px;text-align: right">
              <el-button @click="translate(1)">自动翻译|Automatic Translation|Автоматический перевод</el-button>
            </div>
          </div>
        </div>
        <!-- 品质检查富文本编辑器（中/英/俄） -->
        <div style="margin-top: 10px;text-align: left">
          <span style="font-size: 18px">{{pageVal.qualityInspection}}</span>
          <div>
            <el-tabs v-model="pointsActiveTab" type="card" style="margin-top: 8px">
              <el-tab-pane :label="main.chinese" name="chinese">
                <div ref="qualityCheckChineseEditor" class="editor-container"></div>
              </el-tab-pane>
              <el-tab-pane :label="main.english" name="english">
                <div ref="qualityCheckEnglishEditor" class="editor-container"></div>
              </el-tab-pane>
              <el-tab-pane :label="main.russian" name="russian">
                <div ref="qualityCheckRussianEditor" class="editor-container"></div>
              </el-tab-pane>
            </el-tabs>
          </div>
          <div style="margin-top: 10px;text-align: right">
            <el-button @click="translate(3)">自动翻译|Automatic Translation|Автоматический перевод</el-button>
          </div>
        </div>
        <div>
          <el-tabs v-model="pointsActiveTab" type="card" style="margin-top: 8px">
            <el-tab-pane :label="main.chinese" name="chinese">
              <div style="margin-top: 10px;text-align: left">
                <span style="font-size: 18px">{{pageVal.equipment}}</span>
                <el-input :placeholder="pageVal.enter"
                          v-model="inputText4"
                          style="width: 100%;margin-top: 8px"
                          type="textarea"
                          :rows="1"></el-input>
              </div>
              <div style="margin-top: 10px;text-align: left">
                <span style="font-size: 18px">{{pageVal.accessories}}</span>
                <el-input :placeholder="pageVal.enter"
                          v-model="inputText5"
                          style="width: 100%;margin-top: 8px"
                          type="textarea"
                          :rows="1"></el-input>
              </div>
              <div style="margin-top: 10px;text-align: left">
                <span style="font-size: 18px">{{pageVal.tools}}</span>
                <el-input :placeholder="pageVal.enter"
                          v-model="inputText6"
                          style="width: 100%;margin-top: 8px"
                          type="textarea"
                          :rows="1"></el-input>
              </div>
            </el-tab-pane>
            <el-tab-pane :label="main.english" name="english">
              <div style="margin-top: 10px;text-align: left">
                <span style="font-size: 18px">{{pageVal.equipment}}</span>
                <el-input :placeholder="pageVal.enter"
                          v-model="inputTextEnglish4"
                          style="width: 100%;margin-top: 8px"
                          type="textarea"
                          :rows="1"></el-input>
              </div>
              <div style="margin-top: 10px;text-align: left">
                <span style="font-size: 18px">{{pageVal.accessories}}</span>
                <el-input :placeholder="pageVal.enter"
                          v-model="inputTextEnglish5"
                          style="width: 100%;margin-top: 8px"
                          type="textarea"
                          :rows="1"></el-input>
              </div>
              <div style="margin-top: 10px;text-align: left">
                <span style="font-size: 18px">{{pageVal.tools}}</span>
                <el-input :placeholder="pageVal.enter"
                          v-model="inputTextEnglish6"
                          style="width: 100%;margin-top: 8px"
                          type="textarea"
                          :rows="1"></el-input>
              </div>
            </el-tab-pane>
            <el-tab-pane :label="main.russian" name="russian">
              <div style="margin-top: 10px;text-align: left">
                <span style="font-size: 18px">{{pageVal.equipment}}</span>
                <el-input :placeholder="pageVal.enter"
                          v-model="inputTextRussian4"
                          style="width: 100%;margin-top: 8px"
                          type="textarea"
                          class="russian-input"
                          :rows="1"></el-input>
              </div>
              <div style="margin-top: 10px;text-align: left">
                <span style="font-size: 18px">{{pageVal.accessories}}</span>
                <el-input :placeholder="pageVal.enter"
                          v-model="inputTextRussian5"
                          style="width: 100%;margin-top: 8px"
                          type="textarea"
                          class="russian-input"
                          :rows="1"></el-input>
              </div>
              <div style="margin-top: 10px;text-align: left">
                <span style="font-size: 18px">{{pageVal.tools}}</span>
                <el-input :placeholder="pageVal.enter"
                          v-model="inputTextRussian6"
                          style="width: 100%;margin-top: 8px"
                          type="textarea"
                          class="russian-input"
                          :rows="1"></el-input>
              </div>
            </el-tab-pane>
          </el-tabs>
        </div>
        <div style="margin-top: 10px;text-align: right">
          <el-button @click="translate(4)">自动翻译|Automatic Translation|Автоматический перевод</el-button>
        </div>
        <div style="margin-top: 10px;text-align:center">
          <span style="font-size: 18px">{{pageVal.startingSignal}}</span>
          <el-input :placeholder="pageVal.enter"
                    v-model="inputText7"
                    style="width: 30%;margin-top: 8px;margin-right: 35px"></el-input>
          <span style="font-size: 18px">{{pageVal.endSignal}}</span>
          <el-input :placeholder="pageVal.enter"
                    v-model="inputText8"
                    style="width: 30%;margin-top: 8px;"></el-input>
        </div>
      </div>
      <span slot="footer" class="dialog-footer">
    <el-button @click="dialogVisibleText = false">{{main.cancel}}</el-button>
    <el-button type="primary" @click="saveDataTextTwo">{{main.ok}}</el-button>
  </span>
    </el-dialog>
    <!--做控制计划选择的弹框-->
    <el-dialog
        :title="titleUse"
        :visible.sync="dialogVisibleControl"
        width="85%"
        :before-close="handleClose">
      <div style="display: flex; width: 100%;height: 500px">
        <div style="width: 350px;  border: 1px solid blue;margin-right: 10px;height: 100%;overflow-y: auto">
          <el-tree :data="treeControl" :props="defaultProps" @node-click="controlTreeClick" ></el-tree>
        </div>
        <div style="flex-grow: 1;  border: 1px solid blue;overflow-x: auto;overflow-y: auto">
          <el-table
              ref="multipleTable"
              :data="tableDataControl"
              style="width: 100%"
              height="100%"
              size="mediut"
              @selection-change="controlPlanSelectionChange">
            <el-table-column
                type="selection"
                width="40">
            </el-table-column>
            <el-table-column
                prop="operation"
                :label="pageVal.processName"
                width="150">
            </el-table-column>
            <el-table-column
                prop="device"
                :label="pageVal.device"
                width="150">
            </el-table-column>
            <el-table-column :label="pageVal.characteristic">
              <el-table-column
                  prop="numberOrder"
                  :label="pageVal.number"
                  width="120">
              </el-table-column>
              <el-table-column
                  prop="product"
                  label="产品"
                  width="120">
              </el-table-column>
              <el-table-column
                  prop="processUse"
                  :label="pageVal.process"
                  width="120">
              </el-table-column>
            </el-table-column>
            <el-table-column
                prop="characteristic"
                :label="pageVal.characteristicClassification"
                width="120">
            </el-table-column>
            <el-table-column
                :label="pageVal.method"
                style="text-align: center">
              <el-table-column
                  :label="pageVal.tolerance"
                  width="250px"
                  prop="specification"
                  fixed></el-table-column>
              <el-table-column
                  :label="pageVal.measure"
                  width="100px"
                  prop="measure"></el-table-column>
              <el-table-column
                  :label="pageVal.capacity"
                  width="100px"
                  prop="capacity"></el-table-column>
              <el-table-column
                  :label="pageVal.frequency"
                  width="100px"
                  prop="frequency"></el-table-column>
              <el-table-column
                  :label="pageVal.controlMethod"
                  width="100px"
                  prop="method"></el-table-column>
              <el-table-column
                  :label="pageVal.department"
                  width="100px">
              </el-table-column>
            </el-table-column>
            <el-table-column
                :label="pageVal.reaction"
                width="100px"
                prop="reaction"></el-table-column>
            <el-table-column :label="pageVal.edit" width="220px">
            </el-table-column>
          </el-table>
        </div>
      </div>
      <span slot="footer" class="dialog-footer">
        <el-button @click="loadSelect">{{pageVal.loadPreviousAssociations}}</el-button>
    <el-button @click="dialogVisibleControl = false">{{main.cancel}}</el-button>
    <el-button type="primary" @click="saveDataControl">{{main.ok}}</el-button>
  </span>
    </el-dialog>
    <!--点击上传照片(作业指导书中）-->
    <el-dialog
        :visible.sync="dialogPicture"
        :title="titleUse">
      <div style="margin-top: 10px;text-align: center; border: 1px solid #0269fa;padding: 10px">
        <el-upload
            action="http://10.255.96.48:3499/russiaEngine/"
            list-type="picture-card"
            :auto-upload="false"
            :on-change="(file, fileList) => saveFileAnnex(file, fileList)"
            :file-list="PictureList"
            :accept="fileType">
          <i slot="default" class="el-icon-plus"></i>
          <div slot="file" slot-scope="{file}">
            <img
                class="el-upload-list__item-thumbnail"
                :src="file.url" alt="">
            <span class="el-upload-list__item-actions">
                                <span class="el-upload-list__item-preview" @click="handlePictureCardPreview(file)">
                              <i class="el-icon-zoom-in"></i>
                                </span>
                                <span v-if="!disabled" class="el-upload-list__item-delete" @click="handleDownload(file)">
                                  <i class="el-icon-download"></i>
                                </span>
                                <span v-if="!disabled" class="el-upload-list__item-delete" @click="handleRemove(file)">
                                  <i class="el-icon-delete"></i>
                                </span>
                              </span>
          </div>
        </el-upload>
      </div>
    </el-dialog>
    <!--点击上传视频（作业指导书中）-->
    <el-dialog
        :visible.sync="dialogVideo"
        :title="titleUse">
      <div style="margin-top: 10px;text-align: center; border: 1px solid #0269fa;padding: 10px">
        <el-upload
            action="http://10.255.96.48:3499/russiaEngine/"
            list-type="picture-card"
            :auto-upload="false"
            :on-change="(file, fileList) => saveFileAnnex(file, fileList)"
            :file-list="videoList"
            :accept="fileType"
            v-loading="loading"
            element-loading-text="拼命上传中">
          <i slot="default" class="el-icon-plus"></i>
          <div slot="file" slot-scope="{file}">
            <video width="100%"
                   height="100%"
                   :src="file.url"
                   controls>
            </video>
            <span class="el-upload-list__item-actions">
                                <span class="el-upload-list__item-preview" @click="handlePictureCardPreview(file)">
                              <i class="el-icon-zoom-in"></i>
                                </span>
                                <span v-if="!disabled" class="el-upload-list__item-delete" @click="handleDownload(file)">
                                  <i class="el-icon-download"></i>
                                </span>
                                <span v-if="!disabled" class="el-upload-list__item-delete" @click="handleRemove(file)">
                                  <i class="el-icon-delete"></i>
                                </span>
                              </span>
          </div>
        </el-upload>
      </div>
    </el-dialog>
    <!--点击上传照片(零部件明细中）-->
    <el-dialog
        :visible.sync="dialogPicturePart"
        :title="titleUse">
      <div style="margin-top: 10px;text-align: center; border: 1px solid #0269fa;padding: 10px">
        <el-upload
            action="http://10.255.96.48:3499/russiaEngine/"
            list-type="picture-card"
            :auto-upload="false"
            :on-change="(file, fileList) => saveFileAnnexPart(file, fileList)"
            :file-list="PictureList"
            :accept="fileType">
          <i slot="default" class="el-icon-plus"></i>
          <div slot="file" slot-scope="{file}">
            <img
                class="el-upload-list__item-thumbnail"
                :src="file.url" alt="">
            <span class="el-upload-list__item-actions">
                   <span class="el-upload-list__item-preview" @click="handlePictureCardPreview(file)">
                   <i class="el-icon-zoom-in"></i>
                   </span>
                      <span v-if="!disabled" class="el-upload-list__item-delete" @click="handleDownload(file)">
                          <i class="el-icon-download"></i>
                       </span>
                   <span v-if="!disabled" class="el-upload-list__item-delete" @click="handleRemovePart(file)">
                           <i class="el-icon-delete"></i>
                   </span>
            </span>
          </div>
        </el-upload>
      </div>
    </el-dialog>
    <!--点击上传照片中的放大按钮，查看照片-->
    <el-dialog :visible.sync="dialogPictureAnnex">
      <img width="100%" :src="dialogImageUrl" alt="">
    </el-dialog>
    <!--编辑失效案例的弹窗-->
    <el-dialog
        :title="titleUse"
        :visible.sync="caseUseDialog"
        width="50%"
        :before-close="handleClose">
      <div style="margin-top: 10px;text-align: left">
        <span style="font-size: 18px">{{pageVal.caseDescription}}</span>
        <el-input :placeholder="pageVal.enter"
                  v-model="inputTextCaseUse"
                  style="width: 100%;margin-top: 8px"
                  type="textarea"
                  :rows="3"></el-input>
      </div>
      <span slot="footer" class="dialog-footer">
    <el-button @click="caseUseDialog = false">{{main.cancel}}</el-button>
    <el-button type="primary" @click="caseUseEdit">{{main.ok}}</el-button>
  </span>
    </el-dialog>
    <!--编辑操作人员信息的记录-->
    <el-dialog
        :title="titleUse"
        :visible.sync="operatorDialog"
        width="450px"
        :before-close="handleClose">
      <div style="margin-top: 10px;text-align: left">
        <el-form v-model="operatorListForm" label-width="150px">
          <el-form-item :label="pageVal.employeeId1">
            <el-input style="width: 200px" v-model="operatorListForm.operator_id"></el-input>
          </el-form-item>
          <el-form-item :label="pageVal.name1">
            <el-input style="width: 200px" v-model="operatorListForm.operator_name"></el-input>
          </el-form-item>
          <el-form-item :label="pageVal.startDate1">
            <el-date-picker
                v-model="operatorListForm.star_time"
                format="yyyy-MM-dd"
                value-format="yyyy-MM-dd"
                type="date"
                style="width: 200px"
                :placeholder="pageVal.selectTheDate">
            </el-date-picker>
          </el-form-item>
          <el-form-item :label="pageVal.assessmentLevel">
            <el-select v-model="operatorListForm.skill_level" clearable placeholder="请选择" style="width: 200px">
              <el-option
                  v-for="item in skill_level_options"
                  :key="item.value"
                  :label="item.label"
                  :value="item.value">
              </el-option>
            </el-select>
          </el-form-item>
          <el-form-item :label="pageVal.mentor">
            <el-input style="width: 200px" v-model="operatorListForm.mentor"></el-input>
          </el-form-item>
          <el-form-item :label="pageVal.uploadImage">
            <el-upload
                class="avatar-uploader"
                action=""
                :show-file-list="false"
                :auto-upload="false"
                :on-change="handleAvatarSuccess"
                :before-upload="beforeAvatarUpload">
              <img v-if="operatorListImageUrl" :src="operatorListImageUrl" class="avatar">
              <i v-else class="el-icon-plus avatar-uploader-icon"></i>
            </el-upload>
          </el-form-item>
        </el-form>
      </div>
      <span slot="footer" class="dialog-footer">
    <el-button @click="operatorDialog = false">{{main.cancel}}</el-button>
    <el-button type="primary" @click="operatorListEdit">{{main.ok}}</el-button>
  </span>
    </el-dialog>
    <!--抽屉放置区域-->
    <!--用户点击工序弹出的抽屉-->
    <el-drawer
        :title="drawerTitle"
        :visible.sync="drawer"
        direction="rtl"
        size="50%">
      <el-table
          :data="tableData"
          style="width: 100%;margin-left: 25px;margin-right: 25px"
          highlight-current-row="highlight-current-row">
        <el-table-column
            prop="workshop"
            :label="pageVal.workshop"
            sortable
            width="180"
            v-slot:default="scope">
          <div style="width: 100%" @click="tableDataClick(1,scope)">
            <span v-if="languageS==='chinese'">{{scope.row.workshop.split('/')[0]}}</span>
            <span v-else-if="languageS==='english'">{{scope.row.workshop.split('/')[1]}}</span>
            <span v-else-if="languageS==='russian'">{{scope.row.workshop.split('/')[2]}}</span>
          </div>
        </el-table-column>
        <el-table-column
            prop="lineName"
            :label="pageVal.line"
            sortable
            width="180"
            v-slot:default="scope">
          <div style="width: 100%" @click="tableDataClick(1,scope)">
            <span v-if="languageS==='chinese'">{{scope.row.lineName.split('/')[0]}}</span>
            <span v-else-if="languageS==='english'">{{scope.row.lineName.split('/')[1]}}</span>
            <span v-else-if="languageS==='russian'">{{scope.row.lineName.split('/')[2]}}</span>
          </div>
        </el-table-column>
        <el-table-column
            prop="op"
            :label="pageVal.op"
            sortable
            width="80"
            :formatter="formatter"
            v-slot="scope">
          <div style="width: 100%" @click="tableDataClick(1,scope)">
            {{scope.row.op}}
          </div>
        </el-table-column>
        <el-table-column
            prop="fileName"
            :label="pageVal.fileName"
            v-slot:default="scope">
          <div style="width: 100%" @click="tableDataClick(1,scope)">
            <span v-if="languageS==='chinese' && scope.row.fileName.split('|*|').length===3">{{scope.row.fileName.split('|*|')[0]}}</span>
            <span v-else-if="languageS==='english' && scope.row.fileName.split('|*|').length===3">{{scope.row.fileName.split('|*|')[1]}}</span>
            <span v-else-if="languageS==='russian' && scope.row.fileName.split('|*|').length===3">{{scope.row.fileName.split('|*|')[2]}}</span>
            <span v-else>{{scope.row.fileName}}</span>
          </div>
        </el-table-column>
      </el-table>
    </el-drawer>
    <!--用户点击调用已有的抽屉-->
    <el-drawer
        :title="drawerTitle"
        :visible.sync="drawerCall"
        direction="rtl"
        size="55%">
      <div style="display: flex; width: 100%;">
        <div style="width: 200px; border-right: 1px solid #d3d3d3;">
          <el-tree
              style="margin: 10px 8px;"
              :data="treeList"
              :props="defaultProps"
              @node-click="treeClick1"
              :filter-node-method="filterNode"
              ref="tree"
              highlight-current></el-tree>
        </div>
        <div style="flex: 1; border-left: 1px solid ;">
          <el-table
              :data="tableDataCall"
              highlight-current-row="highlight-current-row">
            <el-table-column
                prop="workshop"
                :label="pageVal.workshop"
                sortable
                width="180"
                v-slot:default="scope">
              <div style="width: 100%" @click="tableDataClickCall(scope)">
                <span v-if="languageS==='chinese'">{{scope.row.workshop.split('/')[0]}}</span>
                <span v-else-if="languageS==='english'">{{scope.row.workshop.split('/')[1]}}</span>
                <span v-else-if="languageS==='russian'">{{scope.row.workshop.split('/')[2]}}</span>
              </div>
            </el-table-column>
            <el-table-column
                prop="lineName"
                :label="pageVal.line"
                sortable
                width="180"
                v-slot:default="scope">
              <div style="width: 100%" @click="tableDataClickCall(scope)">
                <span v-if="languageS==='chinese'">{{scope.row.lineName.split('/')[0]}}</span>
                <span v-else-if="languageS==='english'">{{scope.row.lineName.split('/')[1]}}</span>
                <span v-else-if="languageS==='russian'">{{scope.row.lineName.split('/')[2]}}</span>
              </div>
            </el-table-column>
            <el-table-column
                prop="op"
                :label="pageVal.op"
                sortable
                width="80"
                :formatter="formatter"
                v-slot="scope">
              <div style="width: 100%" @click="tableDataClickCall(scope)">
                {{scope.row.op}}
              </div>
            </el-table-column>
            <el-table-column
                prop="fileName"
                :label="pageVal.fileName"
                v-slot:default="scope">
              <div style="width: 100%" @click="tableDataClickCall(scope)">
                <span v-if="languageS==='chinese' && scope.row.fileName.split('|*|').length===3">{{scope.row.fileName.split('|*|')[0]}}</span>
                <span v-else-if="languageS==='english' && scope.row.fileName.split('|*|').length===3">{{scope.row.fileName.split('|*|')[1]}}</span>
                <span v-else-if="languageS==='russian' && scope.row.fileName.split('|*|').length===3">{{scope.row.fileName.split('|*|')[2]}}</span>
                <span v-else>{{scope.row.fileName}}</span>
              </div>
            </el-table-column>
          </el-table>
        </div>
      </div>
    </el-drawer>
  </div>
</template>

<script>

import _ from "lodash";
import {
  filepath,
  OpAssembly,
  optionWorkshop, tree_workshop_product_op_chinese,
  tree_workshop_product_op_english,
  tree_workshop_product_op_russian,
} from "@/configUse";
import * as echarts from "echarts";
import E from "wangeditor";
import {translate_zh_en_ru} from "@/components/utils/useUtils";

export default {
  name: "operateGuideBook",
  data() {
    //校验数据是否为空
    var dataNull = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('数据不能为空，请输入/选择'));
      }
      callback();
    }
    return {
      activeName:'first',
      //记录控制计划弹窗的树形导航结构
      treeControl:[
          {label: '装配车间',
        children: [
          {
            label: '1000100XEB05',
            children: [
              {
                label: 'OP00'
              },
              {
                label: 'OP10'
              },
              {
                label: 'OP20'
              },
              {
                label: 'OP30-1'
              },
              {
                label: 'OP30'
              },
              {
                label: 'OP40'
              },
              {
                label: 'OP50'
              },
              {
                label: 'OP60'
              },
              {
                label: 'OP70'
              },
              {
                label: 'OP80'
              },
              {
                label: 'OP90'
              },
              {
                label: 'OP100'
              },
              {
                label: 'OP105'
              },
              {
                label: 'OP120'
              },
              {
                label: 'OP130'
              },
              {
                label: 'OP140'
              },
              {
                label: 'OP150'
              },
              {
                label: 'OP155'
              },
              {
                label: 'OP160'
              },
              {
                label: 'OP170'
              },
              {
                label: 'OP180'
              },
              {
                label: 'OP190'
              },
              {
                label: 'OP200'
              },
              {
                label: 'OP210'
              },
              {
                label: 'OP220'
              },
              {
                label: 'OP230'
              },
              {
                label: 'OP240-1'
              },
              {
                label: 'OP240'
              },
              {
                label: 'OP245'
              },
              {
                label: 'OP250'
              },
              {
                label: 'OP260'
              },
              {
                label: 'OP270'
              },
              {
                label: 'OP275'
              },
              {
                label: 'OP280-1'
              },
              {
                label: 'OP280-2'
              },
              {
                label: 'OP280-3'
              },
              {
                label: 'OP280-4'
              },
              {
                label: 'OP280-5'//
              },
              {
                label: 'OP290'
              },
              {
                label: 'OP300'
              },
              {
                label: 'OP310'
              },
              {
                label: 'OP320'
              },
              {
                label: 'OP330'
              },
              {
                label: 'OP340'
              },
              {
                label: 'OP350-1'
              },
              {
                label: 'OP350'
              },
              {
                label: 'OP360'
              },
              {
                label: 'OP370'
              },
              {
                label: 'OP375'
              },
              {
                label: 'OP380'
              },
              {
                label: 'OP390'
              },
              {
                label: 'OP400'
              },
              {
                label: 'OP410-1'
              },
              {
                label: 'OP410'
              },
              {
                label: 'OP420'
              },
              {
                label: 'OP430'
              },
              {
                label: 'OP440-1'
              },
              {
                label: 'OP440'
              },
              {
                label: 'OP450'
              },
              {
                label: 'OP460'
              },
              {
                label: 'OP470'
              },
              {
                label: 'OP480'
              },
              {
                label: 'OP490'
              },
              {
                label: 'OP500'
              },
              {
                label: 'OP510'
              },
              {
                label: 'OP520'
              },
              {
                label: 'OP530'
              },
              {
                label: 'HL10'
              },
              {
                label: 'HL20'
              },
              {
                label: 'HL30'
              },
              {
                label: 'HL35'
              },
              {
                label: 'GG10'
              },
              {
                label: 'GG20'
              },
              {
                label: 'GG30'
              },
              {
                label: 'GG40'
              },
              {
                label: 'GG45'
              },
              {
                label: 'GG50'
              },
              {
                label: 'GG80'
              }
            ]
          },
          {
            label: '1000100XEB75',
            children: [
              {
                label: 'OP00'
              },
              {
                label: 'OP01'
              },
              {
                label: 'OP02'
              },
              {
                label: 'OP03'
              },
              {
                label: 'OP10'
              },
              {
                label: 'OP10'
              },
              {
                label: 'OP20'
              },
              {
                label: 'OP30-1'
              },
              {
                label: 'OP30'
              },
              {
                label: 'OP40'
              },
              {
                label: 'OP50'
              },
              {
                label: 'OP60'
              },
              {
                label: 'OP70'
              },
              {
                label: 'OP80'
              },
              {
                label: 'OP90'
              },
              {
                label: 'OP100'
              },
              {
                label: 'OP105'
              },
              {
                label: 'OP120'
              },
              {
                label: 'OP130'
              },
              {
                label: 'OP140'
              },
              {
                label: 'OP150'
              },
              {
                label: 'OP160'
              },
              {
                label: 'OP170'
              },
              {
                label: 'OP180'
              },
              {
                label: 'OP190'
              },
              {
                label: 'OP200'
              },
              {
                label: 'OP210'
              },
              {
                label: 'OP220'
              },
              {
                label: 'OP230'
              },
              {
                label: 'OP240-1'
              },
              {
                label: 'OP240'
              },
              {
                label: 'OP250'
              },
              {
                label: 'OP260'
              },
              {
                label: 'OP270'
              },
              {
                label: 'OP275'
              },
              {
                label: 'OP280-1'
              },
              {
                label: 'OP280-2'
              },
              {
                label: 'OP280-3'
              },
              {
                label: 'OP280-4'
              },
              {
                label: 'OP280-5'
              },
              {
                label: 'OP290'
              },
              {
                label: 'OP300'
              },
              {
                label: 'OP310'
              },
              {
                label: 'OP320'
              },
              {
                label: 'OP330'
              },
              {
                label: 'OP340'
              },
              {
                label: 'OP350-1'
              },
              {
                label: 'OP350'
              },
              {
                label: 'OP360'
              },
              {
                label: 'OP370'
              },
              {
                label: 'OP380'
              },
              {
                label: 'OP390'
              },
              {
                label: 'OP400'
              },
              {
                label: 'OP410-1'
              },
              {
                label: 'OP410'
              },
              {
                label: 'OP420'
              },
              {
                label: 'OP430'
              },
              {
                label: 'OP440-1'
              },
              {
                label: 'OP440'
              },
              {
                label: 'OP450'
              },
              {
                label: 'OP460'
              },
              {
                label: 'OP470'
              },
              {
                label: 'OP480'
              },
              {
                label: 'OP490'
              },
              {
                label: 'OP500'
              },
              {
                label: 'OP510'
              },
              {
                label: 'OP520'
              },
              {
                label: 'OP530'
              },
              {
                label: 'HL10'
              },
              {
                label: 'HL20'
              },
              {
                label: 'HL30'
              },
              {
                label: 'HL10'
              },
              {
                label: 'HL20'
              },
              {
                label: 'HL30'
              },
              {
                label: 'GG10'
              },
              {
                label: 'GG20'
              },
              {
                label: 'GG30'
              },
              {
                label: 'GG40'
              },
              {
                label: 'GG45'
              },
              {
                label: 'GG50'
              },
              {
                label: 'GG130'
              }
            ]
          },
          {
            label: '1000100XEN19',
            children: [
              {
                label: 'OP00'
              },
              {
                label: 'OP01'
              },
              {
                label: 'OP02'
              },
              {
                label: 'OP03'
              },
              {
                label: 'OP10'
              },
              {
                label: 'OP20'
              },
              {
                label: 'OP30-1'
              },
              {
                label: 'OP30'
              },
              {
                label: 'OP40'
              },
              {
                label: 'OP50'
              },
              {
                label: 'OP60'
              },
              {
                label: 'OP70'
              },
              {
                label: 'OP80'
              },
              {
                label: 'OP90'
              },
              {
                label: 'OP100'
              },
              {
                label: 'OP105'
              },
              {
                label: 'OP120'
              },
              {
                label: 'OP130'
              },
              {
                label: 'OP140'
              },
              {
                label: 'OP150'
              },
              {
                label: 'OP160'
              },
              {
                label: 'OP170'
              },
              {
                label: 'OP180'
              },
              {
                label: 'OP190'
              },
              {
                label: 'OP200'
              },
              {
                label: 'OP210'
              },
              {
                label: 'OP220'
              },
              {
                label: 'OP230'
              },
              {
                label: 'OP240-1'
              },
              {
                label: 'OP240'
              },
              {
                label: 'OP250'
              },
              {
                label: 'OP260'
              },
              {
                label: 'OP270'
              },
              {
                label: 'OP275'
              },
              {
                label: 'OP280-1'
              },
              {
                label: 'OP280-2'
              },
              {
                label: 'OP280-3'
              },
              {
                label: 'OP280-4'
              },
              {
                label: 'OP280-5'
              },
              {
                label: 'OP290'
              },
              {
                label: 'OP300'
              },
              {
                label: 'OP310'
              },
              {
                label: 'OP320'
              },
              {
                label: 'OP330'
              },
              {
                label: 'OP340'
              },
              {
                label: 'OP350-1'
              },
              {
                label: 'OP350'
              },
              {
                label: 'OP360'
              },
              {
                label: 'OP370'
              },
              {
                label: 'OP380'
              },
              {
                label: 'OP390-1'
              },
              {
                label: 'OP390-2'
              },
              {
                label: 'OP390'
              },
              {
                label: 'OP400'
              },
              {
                label: 'OP410-1'
              },
              {
                label: 'OP410'
              },
              {
                label: 'OP420'
              },
              {
                label: 'OP430'
              },
              {
                label: 'OP440-1'
              },
              {
                label: 'OP440'
              },
              {
                label: 'OP450'
              },
              {
                label: 'OP460'
              },
              {
                label: 'OP470'
              },
              {
                label: 'OP480'
              },
              {
                label: 'OP490'
              },
              {
                label: 'OP500'
              },
              {
                label: 'OP510'
              },
              {
                label: 'OP520'
              },
              {
                label: 'OP530'
              },
              {
                label: 'HL10'
              },
              {
                label: 'HL20'
              },
              {
                label: 'HL30'
              },
              {
                label: 'GG10'
              },
              {
                label: 'GG20'
              },
              {
                label: 'GG30'
              },
              {
                label: 'GG40'
              },
              {
                label: 'GG45'
              },
              {
                label: 'GG50'
              },
              {
                label: 'GG130'
              }
            ]
          },
          {
            label: '1000100XEN38',
            children: [
              {
                label: 'OP00'
              },
              {
                label: 'OP01'
              },
              {
                label: 'OP02'
              },
              {
                label: 'OP03'
              },
              {
                label: 'OP10'
              },
              {
                label: 'OP10'
              },
              {
                label: 'OP20'
              },
              {
                label: 'OP30-1'
              },
              {
                label: 'OP30'
              },
              {
                label: 'OP40'
              },
              {
                label: 'OP50'
              },
              {
                label: 'OP60'
              },
              {
                label: 'OP70'
              },
              {
                label: 'OP80'
              },
              {
                label: 'OP90'
              },
              {
                label: 'OP100'
              },
              {
                label: 'OP105'
              },
              {
                label: 'OP120'
              },
              {
                label: 'OP130'
              },
              {
                label: 'OP140'
              },
              {
                label: 'OP150'
              },
              {
                label: 'OP160'
              },
              {
                label: 'OP170'
              },
              {
                label: 'OP180'
              },
              {
                label: 'OP190'
              },
              {
                label: 'OP200'
              },
              {
                label: 'OP210'
              },
              {
                label: 'OP220'
              },
              {
                label: 'OP230'
              },
              {
                label: 'OP240-1'
              },
              {
                label: 'OP240'
              },
              {
                label: 'OP250'
              },
              {
                label: 'OP260'
              },
              {
                label: 'OP270'
              },
              {
                label: 'OP275'
              },
              {
                label: 'OP280-1'
              },
              {
                label: 'OP280-2'
              },
              {
                label: 'OP280-3'
              },
              {
                label: 'OP280-4'
              },
              {
                label: 'OP280-5'
              },
              {
                label: 'OP290'
              },
              {
                label: 'OP300'
              },
              {
                label: 'OP310'
              },
              {
                label: 'OP320'
              },
              {
                label: 'OP330'
              },
              {
                label: 'OP340'
              },
              {
                label: 'OP350-1'
              },
              {
                label: 'OP350'
              },
              {
                label: 'OP360'
              },
              {
                label: 'OP370'
              },
              {
                label: 'OP380'
              },
              {
                label: 'OP390'
              },
              {
                label: 'OP400'
              },
              {
                label: 'OP410-1'
              },
              {
                label: 'OP410'
              },
              {
                label: 'OP420'
              },
              {
                label: 'OP430'
              },
              {
                label: 'OP440-1'
              },
              {
                label: 'OP440'
              },
              {
                label: 'OP450'
              },
              {
                label: 'OP460'
              },
              {
                label: 'OP470'
              },
              {
                label: 'OP480'
              },
              {
                label: 'OP490'
              },
              {
                label: 'OP500'
              },
              {
                label: 'OP510'
              },
              {
                label: 'OP520'
              },
              {
                label: 'OP530'
              },
              {
                label: 'HL10'
              },
              {
                label: 'HL20'
              },
              {
                label: 'HL30'
              },
              {
                label: 'HL10'
              },
              {
                label: 'HL20'
              },
              {
                label: 'HL30'
              },
              {
                label: 'GG10'
              },
              {
                label: 'GG20'
              },
              {
                label: 'GG30'
              },
              {
                label: 'GG40'
              },
              {
                label: 'GG45'
              },
              {
                label: 'GG50'
              },
              {
                label: 'GG130'
              }
            ]
          }
        ]},
          {
      label: '机加车间',
          children: [
      {
        label: '1002100XEB75',
        children: [
          {
            label: 'OP05'
          },
          {
            label: 'OP10-1'
          },
          {
            label: 'OP10-2'
          },
          {
            label: 'OP20-1'
          },
          {
            label: 'OP20-2'
          },
          {
            label: 'OP30-1'
          },
          {
            label: 'OP30-2'
          },
          {
            label: 'OP40-1'
          },
          {
            label: 'OP40-2'
          },
          {
            label: 'OP50-1'
          },
          {
            label: 'OP50-2'
          },
          {
            label: 'OP60'
          },
          {
            label: 'OP70'
          },
          {
            label: 'OP75'
          },
          {
            label: 'OP80'
          },
          {
            label: 'OP90'
          },
          {
            label: 'OP100'
          },
          {
            label: 'OP105'
          },
          {
            label: 'OP110-1'
          },
          {
            label: 'OP110-2'
          },
          {
            label: 'OP120'
          },
          {
            label: 'OP130'
          },
          {
            label: 'OP135'
          },
          {
            label: 'OP140'
          },
          {
            label: 'OP150'
          },
          {
            label: 'OP160'
          },
          {
            label: 'OP170'
          },
        ]
      },
      {
        label: '1003100AEB75',
        children: [
          {
            label: 'OP05'
          },
          {
            label: 'OP10-1'
          },
          {
            label: 'OP10-2'
          },
          {
            label: 'OP20-1'
          },
          {
            label: 'OP20-2'
          },
          {
            label: 'OP30A-1'
          },
          {
            label: 'OP30A-2'
          },
          {
            label: 'OP30B-1'
          },
          {
            label: 'OP30B-2'
          },
          {
            label: 'OP40-1'
          },
          {
            label: 'OP40-2'
          },
          {
            label: 'OP50'
          },
          {
            label: 'OP60'
          },
          {
            label: 'OP70'
          },
          {
            label: 'OP80'
          },
          {
            label: 'OP90-1'
          },
          {
            label: 'OP90-2'
          },
          {
            label: 'OP100-1'
          },
          {
            label: 'OP100-2'
          },
          {
            label: 'OP105'
          },
          {
            label: 'OP110'
          },
          {
            label: 'OP120'
          },
          {
            label: 'OP130'
          },
          {
            label: 'OP140-1'
          },
          {
            label: 'OP140-2'
          },
          {
            label: 'OP150-1'
          },
          {
            label: 'OP150-2'
          },
          {
            label: 'OP160'
          },
          {
            label: 'OP170'
          },
          {
            label: 'OP180'
          },
          {
            label: 'OP190'
          },
          {
            label: 'OP200'
          },
        ]
      },
      {
        label: '1002100XEB05',
        children: [
          {
            label: 'OP05'
          },
          {
            label: 'OP10-1'
          },
          {
            label: 'OP10-2'
          },
          {
            label: 'OP20-1'
          },
          {
            label: 'OP20-2'
          },
          {
            label: 'OP30-1'
          },
          {
            label: 'OP30-2'
          },
          {
            label: 'OP40-1'
          },
          {
            label: 'OP40-2'
          },
          {
            label: 'OP50-1'
          },
          {
            label: 'OP50-2'
          },
          {
            label: 'OP60'
          },
          {
            label: 'OP70'
          },
          {
            label: 'OP75'
          },
          {
            label: 'OP80'
          },
          {
            label: 'OP90'
          },
          {
            label: 'OP100'
          },
          {
            label: 'OP105'
          },
          {
            label: 'OP110-1'
          },
          {
            label: 'OP110-2'
          },
          {
            label: 'OP120'
          },
          {
            label: 'OP130'
          },
          {
            label: 'OP135'
          },
          {
            label: 'OP140'
          },
          {
            label: 'OP150'
          },
          {
            label: 'OP160'
          },
          {
            label: 'OP170'
          },
        ]
      },
      {
        label: '1003100AEB05',
        children: [
          {
            label: 'OP05'
          },
          {
            label: 'OP10-1'
          },
          {
            label: 'OP10-2'
          },
          {
            label: 'OP20A-1'
          },
          {
            label: 'OP20A-2'
          },
          {
            label: 'OP20B-1'
          },
          {
            label: 'OP20B-2'
          },
          {
            label: 'OP30-1'
          },
          {
            label: 'OP30-2'
          },
          {
            label: 'OP40-1'
          },
          {
            label: 'OP40-2'
          },
          {
            label: 'OP50'
          },
          {
            label: 'OP60'
          },
          {
            label: 'OP70'
          },
          {
            label: 'OP80'
          },
          {
            label: 'OP90-1'
          },
          {
            label: 'OP90-2'
          },
          {
            label: 'OP100-1'
          },
          {
            label: 'OP100-2'
          },
          {
            label: 'OP105'
          },
          {
            label: 'OP110'
          },
          {
            label: 'OP120'
          },
          {
            label: 'OP130'
          },
          {
            label: 'OP140-1'
          },
          {
            label: 'OP140-2'
          },
          {
            label: 'OP150-1'
          },
          {
            label: 'OP150-2'
          },
          {
            label: 'OP160'
          },
          {
            label: 'OP170'
          },
          {
            label: 'OP180'
          },
          {
            label: 'OP190'
          },
          {
            label: 'OP200'
          },
        ]
      }
    ]
    },],
      //用户权限相关的变量
      useName:'',//用户名称
      useId:'',//用户编号
      usePower:'',//用户权限
      //语言选择的变量
      languageS:'chinese',
      main:{
        cancel:'取 消',
        ok:'确 定',
        sureToClose:'确认关闭？',
        sureToDelete:'确定删除吗？',
        chinese:'中文',
        english:'英文',
        russian:'俄文',
        qualityManagementSystem:'俄动力质量管理系统',
        operationWorkInstruction:'工序作业指导书',
        selectionPrompt:'选择提示：',
        titleMianId:'未选择产品',
        titleMianOp:'未选择工序',
        filter:'输入关键字进行过滤',
        information:'表单信息',
        line:'线体名称：',
        op:'工序号： ',
        verNoLatest:'版本号：最新',
        dateOfPreparation:'编制日期：',
        implementationDate:'执行日期： ',
        documentNo:'文件编号：',
        preparedBy:'编制： ',
        checked:'审核：',
        approve:'批准：',
        page:'会签：',
        noDataYet:'暂无数据',
        picture:'图片',
        video:'视频',
      },
      pageVal:{
        instruction:'要领书/指导书',
        order:'序号',
        stepContent:'步骤内容',
        attentionPointsExplanation:'注意点说明：',
        qualityInspection:'品质检查：',
        controlPlanRequirements:'控制计划要求：',
        loadPreviousAssociations:'加载以前关联',
        processName:'过程名称/操作描述',
        device:'机器、装置、夹具、工装',
        characteristic:'特性',
        number:'编号',
        product:'产品',
        process:'过程',
        characteristicClassification:'特殊特性分类',
        method:'方法',
        tolerance:'产品/过程规范/公差',
        measure:'评价/测量技术',
        capacity:'容量',
        frequency:'频率',
        controlMethod:'控制方法',
        department:'责任部门',
        reaction:'反应计划',
        tools:'工具：',
        equipment:'设备：',
        accessories:'辅料：',
        startingSignal:'起始信号：',
        endSignal:'结束信号：',
        operationStep:'操作步骤',
        workTime:'工步用时(单位s)',
        focusPoint:'关注点：',
        partDetailsList:'零部件明细',
        add:'新建',
        diagramCode:'图示代码',
        stepNumber:'工步号',
        partName:'零部件名称',
        partNumber:'零部件图号',
        quantity:'数量',
        edit:'编辑',
        partName1:'零件名称',
        assemblyQuantity:'装配数量',
        additionalInformation:'附加信息',
        specialCharacteristics:'特殊特性',
        failureCase:'失效案例库',
        caseDescription:'案例描述',
        manHour:'工时',
        timeDistributionChart:'时间分布图',
        totalDuration:'总时长：',
        operator:'操作人员',
        employeeId:'工号',
        name:'姓名',
        startDate:'开始日期',
        employeeId1:'工号：',
        name1:'姓名：',
        startDate1:'开始日期：',
        assessmentLevel:'考核等级：',
        mentor:'指导人：',
        uploadImage:'上传图片：',
        workshop:'车间名称',
        drawingNumber:'产品图号',
        line:'线体名称',
        op:'工序号',
        verNo:'版本号',
        fileName:'文件名称',
        dateOfPreparation:'编制日期',
        implementationDate:'执行日期',
        designateRelevantPersonnel:'指定相关人员',
        preparedBy:'编制人',
        checked:'审核人',
        countersigned:'会签人',
        approve:'批准人',
        submitResult:'提交结果',
        invokeExisting:'调用已有',
        create:'立即创建',
        cancel:'取消',
        select:'请选择',
        selectTheDate:'选择日期',
        enter:'输入内容',
        enterQuantity:'请输入数量',
        separate:'请输入内容,语言使用“|*|”符号分割',
        specialCharacteristics1:'特殊特性：',
        selfCheckingProjects:'自检项目',
        project:'项目',
        requirement:'检查要求',
      },

      //用在显示不同的样式部分
      //左侧的作业指导书按钮的样式
      background1:'',
      background2:'',
      background3:'',

      //新导航用到的变量
      //导航筛选的变量
      filterText:'',
      // 导航的目录
      treeList:[
        {
          label: '装配车间',
          children: [
            {
              label: '1000100XEB05',
              children: [
                {
                  label: 'OP00'
                },
                {
                  label: 'OP01'
                },
                {
                  label: 'OP02'
                },
                {
                  label: 'OP03'
                },
                {
                  label: 'OP10'
                },
                {
                  label: 'OP20'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30'
                },
                {
                  label: 'OP40'
                },
                {
                  label: 'OP50'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
                {
                  label: 'OP210'
                },
                {
                  label: 'OP220'
                },
                {
                  label: 'OP230'
                },
                {
                  label: 'OP240-1'
                },
                {
                  label: 'OP240'
                },
                {
                  label: 'OP245'
                },
                {
                  label: 'OP250'
                },
                {
                  label: 'OP260'
                },
                {
                  label: 'OP270'
                },
                {
                  label: 'OP275'
                },
                {
                  label: 'OP280-1'
                },
                {
                  label: 'OP280-2'
                },
                {
                  label: 'OP280-3'
                },
                {
                  label: 'OP280-4'
                },
                {
                  label: 'OP280-5'
                },
                {
                  label: 'OP290'
                },
                {
                  label: 'OP300'
                },
                {
                  label: 'OP310'
                },
                {
                  label: 'OP320'
                },
                {
                  label: 'OP330'
                },
                {
                  label: 'OP340'
                },
                {
                  label: 'OP350-1'
                },
                {
                  label: 'OP350'
                },
                {
                  label: 'OP360'
                },
                {
                  label: 'OP370'
                },
                {
                  label: 'OP375'
                },
                {
                  label: 'OP380'
                },
                {
                  label: 'OP390-1'
                },
                {
                  label: 'OP390-2'
                },
                {
                  label: 'OP390'
                },
                {
                  label: 'OP400'
                },
                {
                  label: 'OP410-1'
                },
                {
                  label: 'OP410'
                },
                {
                  label: 'OP420'
                },
                {
                  label: 'OP430'
                },
                {
                  label: 'OP440-1'
                },
                {
                  label: 'OP440'
                },
                {
                  label: 'OP450'
                },
                {
                  label: 'OP460'
                },
                {
                  label: 'OP470'
                },
                {
                  label: 'OP480'
                },
                {
                  label: 'OP490'
                },
                {
                  label: 'OP500'
                },
                {
                  label: 'OP510'
                },
                {
                  label: 'OP520'
                },
                {
                  label: 'OP530'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'GG10'
                },
                {
                  label: 'GG20'
                },
                {
                  label: 'GG30'
                },
                {
                  label: 'GG40'
                },
                {
                  label: 'GG45'
                },
                {
                  label: 'GG50'
                },
                {
                  label: 'GG130'
                }
              ]
            },
            {
              label: '1000100XEN19',
              children: [
                {
                  label: 'OP00'
                },
                {
                  label: 'OP01'
                },
                {
                  label: 'OP02'
                },
                {
                  label: 'OP03'
                },
                {
                  label: 'OP10'
                },
                {
                  label: 'OP20'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30'
                },
                {
                  label: 'OP40'
                },
                {
                  label: 'OP50'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
                {
                  label: 'OP210'
                },
                {
                  label: 'OP220'
                },
                {
                  label: 'OP230'
                },
                {
                  label: 'OP240-1'
                },
                {
                  label: 'OP240'
                },
                {
                  label: 'OP250'
                },
                {
                  label: 'OP260'
                },
                {
                  label: 'OP270'
                },
                {
                  label: 'OP275'
                },
                {
                  label: 'OP280-1'
                },
                {
                  label: 'OP280-2'
                },
                {
                  label: 'OP280-3'
                },
                {
                  label: 'OP280-4'
                },
                {
                  label: 'OP280-5'
                },
                {
                  label: 'OP290'
                },
                {
                  label: 'OP300'
                },
                {
                  label: 'OP310'
                },
                {
                  label: 'OP320'
                },
                {
                  label: 'OP330-1'
                },
                {
                  label: 'OP330'
                },
                {
                  label: 'OP340'
                },
                {
                  label: 'OP350-1'
                },
                {
                  label: 'OP350'
                },
                {
                  label: 'OP360'
                },
                {
                  label: 'OP370'
                },
                {
                  label: 'OP380'
                },
                {
                  label: 'OP390'
                },
                {
                  label: 'OP400'
                },
                {
                  label: 'OP410-1'
                },
                {
                  label: 'OP410'
                },
                {
                  label: 'OP420'
                },
                {
                  label: 'OP430'
                },
                {
                  label: 'OP440-1'
                },
                {
                  label: 'OP440'
                },
                {
                  label: 'OP450'
                },
                {
                  label: 'OP460'
                },
                {
                  label: 'OP470'
                },
                {
                  label: 'OP480'
                },
                {
                  label: 'OP490'
                },
                {
                  label: 'OP500'
                },
                {
                  label: 'OP510'
                },
                {
                  label: 'OP520'
                },
                {
                  label: 'OP530'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'GG10'
                },
                {
                  label: 'GG20'
                },
                {
                  label: 'GG30'
                },
                {
                  label: 'GG40'
                },
                {
                  label: 'GG45'
                },
                {
                  label: 'GG50'
                },
                {
                  label: 'GG80'
                },
                {
                  label: 'GG130'
                }
              ]
            }
          ],

        },
        {
          label: '机加车间',
          children: [
            //EB75缸体
            {
              label: '1002100XEB75',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP50-1'
                },
                {
                  label: 'OP50-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP75'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP110-1'
                },
                {
                  label: 'OP110-2'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP135'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
              ]
            },
            //EB75缸盖
            {
              label: '1003100AEB75',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30A-1'
                },
                {
                  label: 'OP30A-2'
                },
                {
                  label: 'OP30B-1'
                },
                {
                  label: 'OP30B-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90-1'
                },
                {
                  label: 'OP90-2'
                },
                {
                  label: 'OP100-1'
                },
                {
                  label: 'OP100-2'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP110'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140-1'
                },
                {
                  label: 'OP140-2'
                },
                {
                  label: 'OP150-1'
                },
                {
                  label: 'OP150-2'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
              ]
            },
            //EB05缸体
            {
              label: '1002100XEB05',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP50-1'
                },
                {
                  label: 'OP50-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP75'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP110-1'
                },
                {
                  label: 'OP110-2'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP135'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
              ]
            },
            //EB05缸盖
            {
              label: '1003100AEB05',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30A-1'
                },
                {
                  label: 'OP30A-2'
                },
                {
                  label: 'OP30B-1'
                },
                {
                  label: 'OP30B-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90-1'
                },
                {
                  label: 'OP90-2'
                },
                {
                  label: 'OP100-1'
                },
                {
                  label: 'OP100-2'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP110'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140-1'
                },
                {
                  label: 'OP140-2'
                },
                {
                  label: 'OP150-1'
                },
                {
                  label: 'OP150-2'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
              ]
            },
            //EN03缸体
            {
              label: '1002100XEN03',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP50-1'
                },
                {
                  label: 'OP50-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP75'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP110-1'
                },
                {
                  label: 'OP110-2'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP135'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
              ]
            },
            //EN01缸盖
            {
              label: '1003100AEN01',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20A-1'
                },
                {
                  label: 'OP20A-2'
                },
                {
                  label: 'OP20B-1'
                },
                {
                  label: 'OP20B-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90-1'
                },
                {
                  label: 'OP90-2'
                },
                {
                  label: 'OP100-1'
                },
                {
                  label: 'OP100-2'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP110'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140-1'
                },
                {
                  label: 'OP140-2'
                },
                {
                  label: 'OP150-1'
                },
                {
                  label: 'OP150-2'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
              ]
            },
          ]
        }
      ],
      treeListChinese:[
          {
        label: '装配车间',
        children: [
          {
            label: '1000100XEB05',
            children: [
              {
                label: 'OP00'
              },
              {
                label: 'OP01'
              },
              {
                label: 'OP02'
              },
              {
                label: 'OP03'
              },
              {
                label: 'OP10'
              },
              {
                label: 'OP20'
              },
              {
                label: 'OP30-1'
              },
              {
                label: 'OP30'
              },
              {
                label: 'OP40'
              },
              {
                label: 'OP50'
              },
              {
                label: 'OP60'
              },
              {
                label: 'OP70'
              },
              {
                label: 'OP80'
              },
              {
                label: 'OP90'
              },
              {
                label: 'OP100'
              },
              {
                label: 'OP105'
              },
              {
                label: 'OP120'
              },
              {
                label: 'OP130'
              },
              {
                label: 'OP140'
              },
              {
                label: 'OP150'
              },
              {
                label: 'OP160'
              },
              {
                label: 'OP170'
              },
              {
                label: 'OP180'
              },
              {
                label: 'OP190'
              },
              {
                label: 'OP200'
              },
              {
                label: 'OP210'
              },
              {
                label: 'OP220'
              },
              {
                label: 'OP230'
              },
              {
                label: 'OP240-1'
              },
              {
                label: 'OP240'
              },
              {
                label: 'OP245'
              },
              {
                label: 'OP250'
              },
              {
                label: 'OP260'
              },
              {
                label: 'OP270'
              },
              {
                label: 'OP275'
              },
              {
                label: 'OP280-1'
              },
              {
                label: 'OP280-2'
              },
              {
                label: 'OP280-3'
              },
              {
                label: 'OP280-4'
              },
              {
                label: 'OP280-5'
              },
              {
                label: 'OP290'
              },
              {
                label: 'OP300'
              },
              {
                label: 'OP310'
              },
              {
                label: 'OP320'
              },
              {
                label: 'OP330'
              },
              {
                label: 'OP340'
              },
              {
                label: 'OP350-1'
              },
              {
                label: 'OP350'
              },
              {
                label: 'OP360'
              },
              {
                label: 'OP370'
              },
              {
                label: 'OP375'
              },
              {
                label: 'OP380'
              },
              {
                label: 'OP390-1'
              },
              {
                label: 'OP390-2'
              },
              {
                label: 'OP390'
              },
              {
                label: 'OP400'
              },
              {
                label: 'OP410-1'
              },
              {
                label: 'OP410'
              },
              {
                label: 'OP420'
              },
              {
                label: 'OP430'
              },
              {
                label: 'OP440-1'
              },
              {
                label: 'OP440'
              },
              {
                label: 'OP450'
              },
              {
                label: 'OP460'
              },
              {
                label: 'OP470'
              },
              {
                label: 'OP480'
              },
              {
                label: 'OP490'
              },
              {
                label: 'OP500'
              },
              {
                label: 'OP510'
              },
              {
                label: 'OP520'
              },
              {
                label: 'OP530'
              },
              {
                label: 'HL10'
              },
              {
                label: 'HL20'
              },
              {
                label: 'HL30'
              },
              {
                label: 'GG10'
              },
              {
                label: 'GG20'
              },
              {
                label: 'GG30'
              },
              {
                label: 'GG40'
              },
              {
                label: 'GG45'
              },
              {
                label: 'GG50'
              },
              {
                label: 'GG130'
              }
            ]
          },
          {
            label: '1000100XEN19',
            children: [
              {
                label: 'OP00'
              },
              {
                label: 'OP01'
              },
              {
                label: 'OP02'
              },
              {
                label: 'OP03'
              },
              {
                label: 'OP10'
              },
              {
                label: 'OP10'
              },
              {
                label: 'OP20'
              },
              {
                label: 'OP30-1'
              },
              {
                label: 'OP30'
              },
              {
                label: 'OP40'
              },
              {
                label: 'OP50'
              },
              {
                label: 'OP60'
              },
              {
                label: 'OP70'
              },
              {
                label: 'OP80'
              },
              {
                label: 'OP90'
              },
              {
                label: 'OP100'
              },
              {
                label: 'OP105'
              },
              {
                label: 'OP120'
              },
              {
                label: 'OP130'
              },
              {
                label: 'OP140'
              },
              {
                label: 'OP150'
              },
              {
                label: 'OP160'
              },
              {
                label: 'OP170'
              },
              {
                label: 'OP180'
              },
              {
                label: 'OP190'
              },
              {
                label: 'OP200'
              },
              {
                label: 'OP210'
              },
              {
                label: 'OP220'
              },
              {
                label: 'OP230'
              },
              {
                label: 'OP240-1'
              },
              {
                label: 'OP240'
              },
              {
                label: 'OP250'
              },
              {
                label: 'OP260'
              },
              {
                label: 'OP270'
              },
              {
                label: 'OP275'
              },
              {
                label: 'OP280-1'
              },
              {
                label: 'OP280-2'
              },
              {
                label: 'OP280-3'
              },
              {
                label: 'OP280-4'
              },
              {
                label: 'OP280-5'
              },
              {
                label: 'OP290'
              },
              {
                label: 'OP300'
              },
              {
                label: 'OP310'
              },
              {
                label: 'OP320'
              },
              {
                label: 'OP330'
              },
              {
                label: 'OP340'
              },
              {
                label: 'OP350-1'
              },
              {
                label: 'OP350'
              },
              {
                label: 'OP360'
              },
              {
                label: 'OP370'
              },
              {
                label: 'OP380'
              },
              {
                label: 'OP390'
              },
              {
                label: 'OP400'
              },
              {
                label: 'OP410-1'
              },
              {
                label: 'OP410'
              },
              {
                label: 'OP420'
              },
              {
                label: 'OP430'
              },
              {
                label: 'OP440-1'
              },
              {
                label: 'OP440'
              },
              {
                label: 'OP450'
              },
              {
                label: 'OP460'
              },
              {
                label: 'OP470'
              },
              {
                label: 'OP480'
              },
              {
                label: 'OP490'
              },
              {
                label: 'OP500'
              },
              {
                label: 'OP510'
              },
              {
                label: 'OP520'
              },
              {
                label: 'OP530'
              },
              {
                label: 'HL10'
              },
              {
                label: 'HL20'
              },
              {
                label: 'HL30'
              },
              {
                label: 'HL10'
              },
              {
                label: 'HL20'
              },
              {
                label: 'HL30'
              },
              {
                label: 'GG10'
              },
              {
                label: 'GG20'
              },
              {
                label: 'GG30'
              },
              {
                label: 'GG40'
              },
              {
                label: 'GG45'
              },
              {
                label: 'GG50'
              },
              {
                label: 'GG130'
              }
            ]
          }
        ],

      },
          {
          label: '机加车间',
          children: [
            //EB75缸体
            {
              label: '1002100XEB75',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP50-1'
                },
                {
                  label: 'OP50-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP75'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP110-1'
                },
                {
                  label: 'OP110-2'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP135'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
              ]
            },
            //EB75缸盖
            {
              label: '1003100AEB75',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30A-1'
                },
                {
                  label: 'OP30A-2'
                },
                {
                  label: 'OP30B-1'
                },
                {
                  label: 'OP30B-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90-1'
                },
                {
                  label: 'OP90-2'
                },
                {
                  label: 'OP100-1'
                },
                {
                  label: 'OP100-2'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP110'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140-1'
                },
                {
                  label: 'OP140-2'
                },
                {
                  label: 'OP150-1'
                },
                {
                  label: 'OP150-2'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
              ]
            },
            //EB05缸体
            {
              label: '1002100XEB05',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP50-1'
                },
                {
                  label: 'OP50-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP75'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP110-1'
                },
                {
                  label: 'OP110-2'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP135'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
              ]
            },
            //EB05缸盖
            {
              label: '1003100AEB05',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30A-1'
                },
                {
                  label: 'OP30A-2'
                },
                {
                  label: 'OP30B-1'
                },
                {
                  label: 'OP30B-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90-1'
                },
                {
                  label: 'OP90-2'
                },
                {
                  label: 'OP100-1'
                },
                {
                  label: 'OP100-2'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP110'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140-1'
                },
                {
                  label: 'OP140-2'
                },
                {
                  label: 'OP150-1'
                },
                {
                  label: 'OP150-2'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
              ]
            },
            //EN03缸体
            {
              label: '1002100XEN03',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP50-1'
                },
                {
                  label: 'OP50-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP75'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP110-1'
                },
                {
                  label: 'OP110-2'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP135'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
              ]
            },
            //EN01缸盖
            {
              label: '1003100AEN01',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20A-1'
                },
                {
                  label: 'OP20A-2'
                },
                {
                  label: 'OP20B-1'
                },
                {
                  label: 'OP20B-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90-1'
                },
                {
                  label: 'OP90-2'
                },
                {
                  label: 'OP100-1'
                },
                {
                  label: 'OP100-2'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP110'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140-1'
                },
                {
                  label: 'OP140-2'
                },
                {
                  label: 'OP150-1'
                },
                {
                  label: 'OP150-2'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
              ]
            },
          ]
        }
      ],
      treeListEnglish:[
        {
          label: 'Assembly workshop',
          children: [
            {
              label: '1000100XEB05',
              children: [
                {
                  label: 'OP00'
                },
                {
                  label: 'OP01'
                },
                {
                  label: 'OP02'
                },
                {
                  label: 'OP03'
                },
                {
                  label: 'OP10'
                },
                {
                  label: 'OP20'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30'
                },
                {
                  label: 'OP40'
                },
                {
                  label: 'OP50'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
                {
                  label: 'OP210'
                },
                {
                  label: 'OP220'
                },
                {
                  label: 'OP230'
                },
                {
                  label: 'OP240-1'
                },
                {
                  label: 'OP240'
                },
                {
                  label: 'OP245'
                },
                {
                  label: 'OP250'
                },
                {
                  label: 'OP260'
                },
                {
                  label: 'OP270'
                },
                {
                  label: 'OP275'
                },
                {
                  label: 'OP280-1'
                },
                {
                  label: 'OP280-2'
                },
                {
                  label: 'OP280-3'
                },
                {
                  label: 'OP280-4'
                },
                {
                  label: 'OP280-5'
                },
                {
                  label: 'OP290'
                },
                {
                  label: 'OP300'
                },
                {
                  label: 'OP310'
                },
                {
                  label: 'OP320'
                },
                {
                  label: 'OP330'
                },
                {
                  label: 'OP340'
                },
                {
                  label: 'OP350-1'
                },
                {
                  label: 'OP350'
                },
                {
                  label: 'OP360'
                },
                {
                  label: 'OP370'
                },
                {
                  label: 'OP375'
                },
                {
                  label: 'OP380'
                },
                {
                  label: 'OP390-1'
                },
                {
                  label: 'OP390-2'
                },
                {
                  label: 'OP390'
                },
                {
                  label: 'OP400'
                },
                {
                  label: 'OP410-1'
                },
                {
                  label: 'OP410'
                },
                {
                  label: 'OP420'
                },
                {
                  label: 'OP430'
                },
                {
                  label: 'OP440-1'
                },
                {
                  label: 'OP440'
                },
                {
                  label: 'OP450'
                },
                {
                  label: 'OP460'
                },
                {
                  label: 'OP470'
                },
                {
                  label: 'OP480'
                },
                {
                  label: 'OP490'
                },
                {
                  label: 'OP500'
                },
                {
                  label: 'OP510'
                },
                {
                  label: 'OP520'
                },
                {
                  label: 'OP530'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'GG10'
                },
                {
                  label: 'GG20'
                },
                {
                  label: 'GG30'
                },
                {
                  label: 'GG40'
                },
                {
                  label: 'GG45'
                },
                {
                  label: 'GG50'
                },
                {
                  label: 'GG130'
                }
              ]
            },
            {
              label: '1000100XEN19',
              children: [
                {
                  label: 'OP00'
                },
                {
                  label: 'OP01'
                },
                {
                  label: 'OP02'
                },
                {
                  label: 'OP03'
                },
                {
                  label: 'OP10'
                },
                {
                  label: 'OP10'
                },
                {
                  label: 'OP20'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30'
                },
                {
                  label: 'OP40'
                },
                {
                  label: 'OP50'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
                {
                  label: 'OP210'
                },
                {
                  label: 'OP220'
                },
                {
                  label: 'OP230'
                },
                {
                  label: 'OP240-1'
                },
                {
                  label: 'OP240'
                },
                {
                  label: 'OP250'
                },
                {
                  label: 'OP260'
                },
                {
                  label: 'OP270'
                },
                {
                  label: 'OP275'
                },
                {
                  label: 'OP280-1'
                },
                {
                  label: 'OP280-2'
                },
                {
                  label: 'OP280-3'
                },
                {
                  label: 'OP280-4'
                },
                {
                  label: 'OP280-5'
                },
                {
                  label: 'OP290'
                },
                {
                  label: 'OP300'
                },
                {
                  label: 'OP310'
                },
                {
                  label: 'OP320'
                },
                {
                  label: 'OP330'
                },
                {
                  label: 'OP340'
                },
                {
                  label: 'OP350-1'
                },
                {
                  label: 'OP350'
                },
                {
                  label: 'OP360'
                },
                {
                  label: 'OP370'
                },
                {
                  label: 'OP380'
                },
                {
                  label: 'OP390'
                },
                {
                  label: 'OP400'
                },
                {
                  label: 'OP410-1'
                },
                {
                  label: 'OP410'
                },
                {
                  label: 'OP420'
                },
                {
                  label: 'OP430'
                },
                {
                  label: 'OP440-1'
                },
                {
                  label: 'OP440'
                },
                {
                  label: 'OP450'
                },
                {
                  label: 'OP460'
                },
                {
                  label: 'OP470'
                },
                {
                  label: 'OP480'
                },
                {
                  label: 'OP490'
                },
                {
                  label: 'OP500'
                },
                {
                  label: 'OP510'
                },
                {
                  label: 'OP520'
                },
                {
                  label: 'OP530'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'GG10'
                },
                {
                  label: 'GG20'
                },
                {
                  label: 'GG30'
                },
                {
                  label: 'GG40'
                },
                {
                  label: 'GG45'
                },
                {
                  label: 'GG50'
                },
                {
                  label: 'GG130'
                }
              ]
            }
          ],

        },
        {
          label: 'Machining workshop',
          children: [
            //EB75缸体
            {
              label: '1002100XEB75',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP50-1'
                },
                {
                  label: 'OP50-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP75'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP110-1'
                },
                {
                  label: 'OP110-2'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP135'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
              ]
            },
            //EB75缸盖
            {
              label: '1003100AEB75',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30A-1'
                },
                {
                  label: 'OP30A-2'
                },
                {
                  label: 'OP30B-1'
                },
                {
                  label: 'OP30B-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90-1'
                },
                {
                  label: 'OP90-2'
                },
                {
                  label: 'OP100-1'
                },
                {
                  label: 'OP100-2'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP110'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140-1'
                },
                {
                  label: 'OP140-2'
                },
                {
                  label: 'OP150-1'
                },
                {
                  label: 'OP150-2'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
              ]
            },
            //EB05缸体
            {
              label: '1002100XEB05',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP50-1'
                },
                {
                  label: 'OP50-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP75'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP110-1'
                },
                {
                  label: 'OP110-2'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP135'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
              ]
            },
            //EB05缸盖
            {
              label: '1003100AEB05',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30A-1'
                },
                {
                  label: 'OP30A-2'
                },
                {
                  label: 'OP30B-1'
                },
                {
                  label: 'OP30B-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90-1'
                },
                {
                  label: 'OP90-2'
                },
                {
                  label: 'OP100-1'
                },
                {
                  label: 'OP100-2'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP110'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140-1'
                },
                {
                  label: 'OP140-2'
                },
                {
                  label: 'OP150-1'
                },
                {
                  label: 'OP150-2'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
              ]
            },
            //EN03缸体
            {
              label: '1002100XEN03',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP50-1'
                },
                {
                  label: 'OP50-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP75'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP110-1'
                },
                {
                  label: 'OP110-2'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP135'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
              ]
            },
            //EN01缸盖
            {
              label: '1003100AEN01',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20A-1'
                },
                {
                  label: 'OP20A-2'
                },
                {
                  label: 'OP20B-1'
                },
                {
                  label: 'OP20B-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90-1'
                },
                {
                  label: 'OP90-2'
                },
                {
                  label: 'OP100-1'
                },
                {
                  label: 'OP100-2'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP110'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140-1'
                },
                {
                  label: 'OP140-2'
                },
                {
                  label: 'OP150-1'
                },
                {
                  label: 'OP150-2'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
              ]
            },
          ]
        }
      ],
      treeListRussian:[
        {
          label: 'Сборочная линия',
          children: [
            {
              label: '1000100XEB05',
              children: [
                {
                  label: 'OP00'
                },
                {
                  label: 'OP01'
                },
                {
                  label: 'OP02'
                },
                {
                  label: 'OP03'
                },
                {
                  label: 'OP10'
                },
                {
                  label: 'OP20'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30'
                },
                {
                  label: 'OP40'
                },
                {
                  label: 'OP50'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
                {
                  label: 'OP210'
                },
                {
                  label: 'OP220'
                },
                {
                  label: 'OP230'
                },
                {
                  label: 'OP240-1'
                },
                {
                  label: 'OP240'
                },
                {
                  label: 'OP245'
                },
                {
                  label: 'OP250'
                },
                {
                  label: 'OP260'
                },
                {
                  label: 'OP270'
                },
                {
                  label: 'OP275'
                },
                {
                  label: 'OP280-1'
                },
                {
                  label: 'OP280-2'
                },
                {
                  label: 'OP280-3'
                },
                {
                  label: 'OP280-4'
                },
                {
                  label: 'OP280-5'
                },
                {
                  label: 'OP290'
                },
                {
                  label: 'OP300'
                },
                {
                  label: 'OP310'
                },
                {
                  label: 'OP320'
                },
                {
                  label: 'OP330'
                },
                {
                  label: 'OP340'
                },
                {
                  label: 'OP350-1'
                },
                {
                  label: 'OP350'
                },
                {
                  label: 'OP360'
                },
                {
                  label: 'OP370'
                },
                {
                  label: 'OP375'
                },
                {
                  label: 'OP380'
                },
                {
                  label: 'OP390-1'
                },
                {
                  label: 'OP390-2'
                },
                {
                  label: 'OP390'
                },
                {
                  label: 'OP400'
                },
                {
                  label: 'OP410-1'
                },
                {
                  label: 'OP410'
                },
                {
                  label: 'OP420'
                },
                {
                  label: 'OP430'
                },
                {
                  label: 'OP440-1'
                },
                {
                  label: 'OP440'
                },
                {
                  label: 'OP450'
                },
                {
                  label: 'OP460'
                },
                {
                  label: 'OP470'
                },
                {
                  label: 'OP480'
                },
                {
                  label: 'OP490'
                },
                {
                  label: 'OP500'
                },
                {
                  label: 'OP510'
                },
                {
                  label: 'OP520'
                },
                {
                  label: 'OP530'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'GG10'
                },
                {
                  label: 'GG20'
                },
                {
                  label: 'GG30'
                },
                {
                  label: 'GG40'
                },
                {
                  label: 'GG45'
                },
                {
                  label: 'GG50'
                },
                {
                  label: 'GG130'
                }
              ]
            },
            {
              label: '1000100XEN19',
              children: [
                {
                  label: 'OP00'
                },
                {
                  label: 'OP01'
                },
                {
                  label: 'OP02'
                },
                {
                  label: 'OP03'
                },
                {
                  label: 'OP10'
                },
                {
                  label: 'OP10'
                },
                {
                  label: 'OP20'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30'
                },
                {
                  label: 'OP40'
                },
                {
                  label: 'OP50'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
                {
                  label: 'OP210'
                },
                {
                  label: 'OP220'
                },
                {
                  label: 'OP230'
                },
                {
                  label: 'OP240-1'
                },
                {
                  label: 'OP240'
                },
                {
                  label: 'OP250'
                },
                {
                  label: 'OP260'
                },
                {
                  label: 'OP270'
                },
                {
                  label: 'OP275'
                },
                {
                  label: 'OP280-1'
                },
                {
                  label: 'OP280-2'
                },
                {
                  label: 'OP280-3'
                },
                {
                  label: 'OP280-4'
                },
                {
                  label: 'OP280-5'
                },
                {
                  label: 'OP290'
                },
                {
                  label: 'OP300'
                },
                {
                  label: 'OP310'
                },
                {
                  label: 'OP320'
                },
                {
                  label: 'OP330'
                },
                {
                  label: 'OP340'
                },
                {
                  label: 'OP350-1'
                },
                {
                  label: 'OP350'
                },
                {
                  label: 'OP360'
                },
                {
                  label: 'OP370'
                },
                {
                  label: 'OP380'
                },
                {
                  label: 'OP390'
                },
                {
                  label: 'OP400'
                },
                {
                  label: 'OP410-1'
                },
                {
                  label: 'OP410'
                },
                {
                  label: 'OP420'
                },
                {
                  label: 'OP430'
                },
                {
                  label: 'OP440-1'
                },
                {
                  label: 'OP440'
                },
                {
                  label: 'OP450'
                },
                {
                  label: 'OP460'
                },
                {
                  label: 'OP470'
                },
                {
                  label: 'OP480'
                },
                {
                  label: 'OP490'
                },
                {
                  label: 'OP500'
                },
                {
                  label: 'OP510'
                },
                {
                  label: 'OP520'
                },
                {
                  label: 'OP530'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'GG10'
                },
                {
                  label: 'GG20'
                },
                {
                  label: 'GG30'
                },
                {
                  label: 'GG40'
                },
                {
                  label: 'GG45'
                },
                {
                  label: 'GG50'
                },
                {
                  label: 'GG130'
                }
              ]
            }
          ],

        },
        {
          label: 'Цех механической обработки',
          children: [
            //EB75缸体
            {
              label: '1002100XEB75',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP50-1'
                },
                {
                  label: 'OP50-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP75'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP110-1'
                },
                {
                  label: 'OP110-2'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP135'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
              ]
            },
            //EB75缸盖
            {
              label: '1003100AEB75',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30A-1'
                },
                {
                  label: 'OP30A-2'
                },
                {
                  label: 'OP30B-1'
                },
                {
                  label: 'OP30B-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90-1'
                },
                {
                  label: 'OP90-2'
                },
                {
                  label: 'OP100-1'
                },
                {
                  label: 'OP100-2'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP110'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140-1'
                },
                {
                  label: 'OP140-2'
                },
                {
                  label: 'OP150-1'
                },
                {
                  label: 'OP150-2'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
              ]
            },
            //EB05缸体
            {
              label: '1002100XEB05',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP50-1'
                },
                {
                  label: 'OP50-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP75'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP110-1'
                },
                {
                  label: 'OP110-2'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP135'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
              ]
            },
            //EB05缸盖
            {
              label: '1003100AEB05',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30A-1'
                },
                {
                  label: 'OP30A-2'
                },
                {
                  label: 'OP30B-1'
                },
                {
                  label: 'OP30B-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90-1'
                },
                {
                  label: 'OP90-2'
                },
                {
                  label: 'OP100-1'
                },
                {
                  label: 'OP100-2'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP110'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140-1'
                },
                {
                  label: 'OP140-2'
                },
                {
                  label: 'OP150-1'
                },
                {
                  label: 'OP150-2'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
              ]
            },
            //EN03缸体
            {
              label: '1002100XEN03',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP50-1'
                },
                {
                  label: 'OP50-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP75'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP110-1'
                },
                {
                  label: 'OP110-2'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP135'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
              ]
            },
            //EN01缸盖
            {
              label: '1003100AEN01',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20A-1'
                },
                {
                  label: 'OP20A-2'
                },
                {
                  label: 'OP20B-1'
                },
                {
                  label: 'OP20B-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90-1'
                },
                {
                  label: 'OP90-2'
                },
                {
                  label: 'OP100-1'
                },
                {
                  label: 'OP100-2'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP110'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140-1'
                },
                {
                  label: 'OP140-2'
                },
                {
                  label: 'OP150-1'
                },
                {
                  label: 'OP150-2'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
              ]
            },
          ]
        }
      ],
      //树形的导航用到的数据模板
      defaultProps: {
        children: 'children',
        label: 'label'
      },
      //点击的树形结构内容Data
      treeData:null,
      //点击的树形结构内容
      treeNode:null,

      //用作作业指导书表头部分的选择
      workBookHeard1:'#0269fa',
      workBookHeard2:'',
      workBookHeard3:'',
      workBookHeard4:'',
      workBookHeard5:'',
      workBookHeardColour1:'white',
      workBookHeardColour2:'',
      workBookHeardColour3:'',
      workBookHeardColour4:'',
      workBookHeardColour5:'',

      //图片、视频切换的按钮样式变量
      videoAndImage1:'#0269fa',
      videoAndImage2:'',
      //图片、视频切换的按钮颜色变化
      videoAndImageColor1:'white',
      videoAndImageColor2:'',

      //富文本的变量
      //注意点说明：
      pointsChineseEditor: null,
      pointsEnglishEditor: null,
      pointsRussianEditor: null,
      //品质检查：
      qualityCheckChineseEditor: null,
      qualityCheckEnglishEditor: null,
      qualityCheckRussianEditor: null,

      // 当前激活的tab
      pointsActiveTab: 'chinese',
      qualityActiveTab: 'chinese',

      //抽屉用到的变量
      //控制抽屉的表头
      drawerTitle:'',
      //控制抽屉打开
      drawer:false,
      //调用已有的抽屉
      drawerCall:false,
      //数据大表，记录工序作业指导书的
      tableData:[
        {
          //主键
          id:'',
          //车间名称
          workshop:'',
          //线体名称
          lineName:'',
          //工序名称
          op:'',
          //文件名称
          fileName:'',
          //版本号
          editionNum:'',
          //编制日期
          writeDate:'',
          //执行日期
          executeDate:'',
          //文件编号
          fileNum:'',
          //编制
          writeUse:'',
          //审核
          examineUse:'',
          //批准
          ratifyUse:'',
          //会签
          countersignUse:'',
          //作业指导书
          workBook:'',
          //产品图号
          productId:'',
          //视频附件
          BookVideo:'',
          //设备配合动作分解
          deviceTime:'',
          //修改记录
          editRecord:'',
          //控制计划标记位
          controlSign:'',
          //三不检验指导书标记位
          threeBookSign:'',
          //装配零部件明细
          partsList:'',
          //指导书类型
          bookType:'',
          //失效案例
          caseUse:'',
          //操作人员的信息
          operator:'',
          //删除标记位
          deleteSign:'',
          //创建时间
          establishTime:'',
          //修改时间
          UpdateTime:'',
        }
      ],
      //数据大表，记录工序作业指导书的备份，就是给调用的时候作为备份
      tableDataCall:[
        {
          //主键
          id:'',
          //车间名称
          workshop:'',
          //线体名称
          lineName:'',
          //工序名称
          op:'',
          //文件名称
          fileName:'',
          //版本号
          editionNum:'',
          //编制日期
          writeDate:'',
          //执行日期
          executeDate:'',
          //文件编号
          fileNum:'',
          //编制
          writeUse:'',
          //审核
          examineUse:'',
          //批准
          ratifyUse:'',
          //会签
          countersignUse:'',
          //作业指导书
          workBook:'',
          //产品图号
          productId:'',
          //视频附件
          BookVideo:'',
          //设备配合动作分解
          deviceTime:'',
          //修改记录
          editRecord:'',
          //控制计划标记位
          controlSign:'',
          //三不检验指导书标记位
          threeBookSign:'',
          //装配零部件明细
          partsList:'',
          //指导书类型
          bookType:'',
          //失效案例
          caseUse:'',
          //删除标记位
          deleteSign:'',
          //创建时间
          establishTime:'',
          //修改时间
          UpdateTime:'',
        }
      ],
      //编辑大表的临时中转变量
      tableDataTemp: {
        //主键
        id: '',
        //车间名称
        workshop: '',
        //线体名称
        lineName: '',
        //工序名称
        op: '',
        //文件名称
        fileName: '',
        //版本号
        editionNum: '',
        //编制日期
        writeDate: '',
        //执行日期
        executeDate: '',
        //文件编号
        fileNum: '',
        //编制
        writeUse: '',
        //审核
        examineUse: '',
        //批准
        ratifyUse: '',
        //会签
        countersignUse: '',
        //作业指导书
        workBook: '',
        //产品图号
        productId: '',
        //视频附件
        bookVideo: '',
        //修改记录
        editRecord: '',
        //控制计划标记位
        controlSign: '',
        //三不检验指导书标记位
        threeBookSign: '',
        //装配零部件明细
        partsList: '',
        //指导书类型
        bookType: '',
        //删除标记位
        deleteSign: '',
        //创建时间
        establishTime: '',
        //修改时间
        UpdateTime: '',
      },
      //表单输入的控件变量
      formTableData:{
        //主键
        id: '',
        //车间名称
        workshop: '',
        //线体名称
        lineName: '',
        //工序名称
        op: '',
        //文件名称
        fileName: '',
        //版本号
        editionNum: '',
        //编制日期
        writeDate: '',
        //执行日期
        executeDate: '',
        //文件编号
        fileNum: '',
        //编制
        writeUse: '',
        //审核
        examineUse: '',
        //批准
        ratifyUse: '',
        //会签
        countersignUse: '',
        //作业指导书
        workBook: '',
        //产品图号
        productId: '',
        //视频附件
        bookVideo: '',
        //修改记录
        editRecord: '',
        //控制计划标记位
        controlSign: '',
        //三不检验指导书标记位
        threeBookSign: '',
        //装配零部件明细
        partsList: '',
        //指导书类型
        bookType: '',
        //删除标记位
        deleteSign: '',
        //创建时间
        establishTime: '',
        //修改时间
        UpdateTime: '',
      },
      //表单校验变量
      rulesForm:{
        workshop:[{ validator: dataNull, trigger: 'blur'},],
        lineName:[{ validator: dataNull, trigger: 'blur'},],
        op:[{ validator: dataNull, trigger: 'blur'},],
        fileName:[{ validator: dataNull, trigger: 'blur'},],
        editionNum:[{ validator: dataNull, trigger: 'blur'},],
        writeDate:[{ validator: dataNull, trigger: 'blur'},],
        executeDate:[{ validator: dataNull, trigger: 'blur'},],
        examineUse:[{ validator: dataNull, trigger: 'blur'},],
        ratifyUse:[{ validator: dataNull, trigger: 'blur'},],
        countersignUse:[{ validator: dataNull, trigger: 'blur'},]
      },
      //作业指导书的数据表
      workBook:[
        {
          id:0,
          work:'请编辑',//工作项目
          problem:'请输入',//关注点
          inspect:'请输入',//品质检查
          spendTime:'',//需要时间
          controlPlan:0,//控制计划的关联项
          toll:'',//工具
          device:'',//设备
          accessories:'',//辅料,
          pictureList:'',//图片列表
          videoList:'',//视频列表

          //2025年新增加的内容，是作为标准作业引导来的
          startSignal:'',//开始信号的标记
          endSignal:'',//结束信号的标记
        }
      ],
      //记录部件明细
      partsListData:[
        {
          // 图示代码
          mapId:'',
        // 工步号
        stepNum:'',
        // 零部件编号
        partId:'',
        // 零部件名称
        partName:'',
        // 数量
        partNum:'',
        // 特殊特性
        special:'',
        // 最后编辑时间
        endDate:'',
          //最后编辑人
          endName:'',
        // 图片列表
        imageList:'',
        // 预留
        reserve1:'',
        // 预留
        reserve2:'',
        // 预留
        reserve3:'',
        }
      ],
      //记录部件的临时编辑变量
      partsListFrom:{
        // 图示代码
        mapId:'',
        // 工步号
        stepNum:'',
        // 零部件编号
        partId:'',
        // 零部件名称
        partName:'',
        // 数量
        partNum:'',
        // 特殊特性
        special:'',
        // 最后编辑时间
        endDate:'',
        //最后编辑人
        endName:'',
        // 图片列表
        imageList:'',
        // 预留
        reserve1:'',
        // 预留
        reserve2:'',
        // 预留
        reserve3:'',
      },
      //记录部件的点击状态：1.新增；2编辑；3.向下插入；4：删除
      partsListDoe:0,
      //记录部件的点击行内容，Scope格式
      partsListScope:null,

      //记录零部件下的检验项目，表明在这个零部件下，需要看那些内容
      partCheckListData:[
        {
          //主键
          id:0,
          //检查项目
          project:'',
          //检查要求
          requirement:'',
          //图片列表
          pictureList:'',
          //视频列表
          videoList:'',
        }
      ],

      //选择零部件的变量
      partsListOptions:[],

      //作业指导书控制计划部分的数据集合
      controlPlanData:[
        {
          //主键
          id:-1,
          //产品/过程规范/公差
          specification:'',
          //评价
          measure:'',
          //容量
          capacity:'',
          //频率
          frequency:'',
          //控制方法
          method:'',
        },
      ],
      controlPlanForm: {
          //主键
          id:-1,
          //产品/过程规范/公差
          specification:'',
          //评价
          measure:'',
          //容量
          capacity:'',
          //频率
          frequency:'',
          //控制方法
          method:'',
        },
      controlPlanScope:'',

      //控制计划的列表展示
      tableDataControl:[
        {
          //记录主键ID
          id: null,
          //零件/过程编号
          processNumber: '',
          processNumberEnglish:'',
          processNumberRussian:'',
          //机器、夹具、装置、工装
          device: '',
          deviceEnglish:'',
          deviceRussian:'',
          //过程名称/操作描述
          operation: '',
          operationEnglish:'',
          operationRussian:'',
          //编号
          numberOrder: '',
          //产品
          product: '',
          productEnglish:'',
          productRussian:'',
          //过程
          processUse: '',
          processUseEnglish:'',
          processUseRussian:'',
          //特殊特性分类
          characteristic:'',
          //产品、过程规范、公差
          specification: '',
          specificationEnglish:'',
          specificationRussian:'',
          //评价、测量技术
          measure: '',
          measureEnglish:'',
          measureRussian:'',
          //容量
          capacity: '',
          capacityEnglish:'',
          capacityRussian:'',
          //频率
          frequency: '',
          frequencyEnglish:'',
          frequencyRussian:'',
          //控制方法
          method: '',
          methodEnglish:'',
          methodRussian:'',
          //责任部门
          department: '',
          departmentEnglish:'',
          departmentRussian:'',
          //反应计划
          reaction:0,
          //产品图号
          drawing: '',
          //工序号
          op: 0,
          //车间名称
          workshop:'',
          workshopEnglish:'',
          workshopRussian:'',
          //记录顺序用
          orderNumber:0,
          //记录删除标记
          deleteSign:1,
        }
      ],
      //固定选择器用到的变量
      //车间名称
      optionWorkshop: optionWorkshop,
      //线体名称
      optionLine:[
        {
          value:'总成线/Assembly line/сборочная линия',
          label:'总成线/Assembly line/сборочная линия'
        },
        {
          value:'缸盖分装线/Cylinder head assembly line/сборочная линия головки блока цилиндров',
          label:'缸盖分装线/Cylinder head assembly line/сборочная линия головки блока цилиндров'
        },
        {
          value:'热试线/Hot test line/Тепловая линия',
          label:'热试线/Hot test line/Тепловая линия'
        },
        {
          value:'缸体线/Cylinder block line/ линия блока цилиндров',
          label:'缸体线/Cylinder block line/ линия блока цилиндров'
        },
        {
          value:'缸盖线/Cylinder head line/линия головки блока цилиндров',
          label:'缸盖线/Cylinder head line/линия головки блока цилиндров'
        }
      ],
      //工序名称
      optionOp:OpAssembly,
      //版本号
      optionEditionNum:[{
        value:1,
        label:'最新'
      },],
      //线体名称选择器的控制是否可以用
      disabledLineName:true,
      //工序的选择器，控制是否可用
      disabledOp:false,
      //弹窗用到的变量
      titleUse:'提示',
      //判断用户要删除哪个数据
      deleteDataDoe:'',
      //确定删除的弹窗
      deleteDialog:false,
      //控制编辑作业指导书的步骤的弹窗
      dialogVisibleText:false,
      //控制表头的变量编辑的弹窗
      dialogTableHeader:false,
      //上传图片的弹窗打开后，点击放大管控弹窗提示
      dialogPictureAnnex:false,
      //上传照片的弹窗
      dialogPicture:false,
      //上传视频的弹窗
      dialogVideo:false,
      //打开控制计划的编辑器
      dialogVisibleControl:false,
      //控制打开零部件编辑弹窗
      partsListDialog:false,
      //控制零部件明细中的图片弹窗
      dialogPicturePart:false,
      //控制失效案例库的弹窗
      caseUseDialog:false,
      //控制编辑员工信息的弹窗
      operatorDialog:false,

      //图片相关的数据，录像相关的项目
      itemView:[],//展示图片了路径,用在了走马灯部位
      itemViewVideo:[],//展示了录像的路径，用在录像的走马灯上
      editPictureType:0,//修改图片的类型，主要记录了
      PictureList:[],//图片文件的
      videoList:[],//录像的文件列表
      disabled:false,//图片显示的控制变量
      dialogImageUrl:'',//弹窗显示的图片路径
      videoUrl:'',//视频的地址
      fileType:'',//限定上传文件的类型

      //弹窗用到的输入变量
      inputText1:'',//记录作业步骤
      inputTextEnglish1:'',//记录作业步骤英文
      inputTextRussian1:'',//记录作业步骤英文
      inputText4:'',//设备名称
      inputTextEnglish4:'',//设备名称英文
      inputTextRussian4:'',//设备名称俄文
      inputText5:'',//辅料名称
      inputTextEnglish5:'',//辅料名称英文
      inputTextRussian5:'',//辅料名称俄文
      inputText6:'',//工具名称
      inputTextEnglish6:'',//工具名称英文
      inputTextRussian6:'',//工具名称俄文
      inputText7:'',//开始信号
      inputText8:'',//结束信号
      inputNum:0,//用户输入的时间

      //用户现在的类型是什么
      typeTableUse:0,//选择的哪一类作业指导书
      tableDataScope:null,//选择的总表内容传递
      editBookUse:0,//用户选择对作业要领书编辑的内容
      editBookScope:null,//用户现在的作业指导书内容传递
      editTableUse:0,//记录编辑表头的类型，1：插入，2.编辑，3.删除
      editVideoAndImageUse:1,//记录用户选择的是看图片，还是看视频。1:看图片；2:看视频；
      workBookHeardUse:1,//记录用户选择的看作业指导书上的那个类型，1代表是作业指导书；2.

      //记录合格的操作者的信息,大表信息
      operatorList:[
        {
          //主键
          id:'',
          //工号
          operator_id:'',
          //姓名
          operator_name:'',
          //开始时间
          star_time:'',
          //技能等级
          skill_level:'1/4',
          //指导人
          mentor:'',
          //员工图片路径
          operator_path:'',
          //预留
          reserved1:'',
          reserved2:'',
          reserved3:'',
          reserved4:'',
          reserved5:'',
        }
      ],
      //记录合格操作者信息，表单
      operatorListForm:{
        //主键
        id:'',
        //工号
        operator_id:'',
        //姓名
        operator_name:'',
        //开始时间
        star_time:'',
        //技能等级
        skill_level:'1/4',
        //指导人
        mentor:'',
        //员工图片路径
        operator_path:'',
        //预留
        reserved1:'',
        reserved2:'',
        reserved3:'',
        reserved4:'',
        reserved5:'',
      },
      //记录用户要实行哪类操作
      operatorListDoe:0,
      //记录用户点击的是哪一行
      operatorListScope:null,
      //上传人员的图像
      operatorListImageUrl:null,
      //存储上传的人员图片文件，包括文件名称、本体中。
      operatorListFile:null,

      //选择控制计划条目是那个,记录的是选择的本行所有内容。
      controlPlanSelection:[],
      //选择的控制计划的ID是什么，是一个数据合集。
      controlPlanSelectionId:'',

      //等查询完毕控制计划关联项后，开始显示元素
      isControlPlanLoad:false,

      //员工等级的选择器
      skill_level_options:[
        {label:'1/4',value: '1/4'},
        {label:'2/4',value: '2/4'},
        {label:'3/4',value: '3/4'},
        {label:'4/4',value: '4/4'},
      ],

      //忙加载
      loading:false,

      //画工时的直方图
      //画直方图
      chartUserBor:null,
      optionBor: {
        title: {
          text: '无信息',        // 主标题文本
          subtext:'',              //副标题
          left: 'center',         // 标题位置（left/center/right/数值）
          top: 'top',             // 标题垂直位置（top/center/bottom/数值）
          textStyle: {
            color: '#333',        // 标题颜色
            fontSize: 18,         // 标题字号
            fontWeight: 'bold'    // 字体粗细
          },
          subtextStyle: {
            color: '#aaa'         // 副标题样式
          }
        },
        tooltip: {
          trigger: 'axis',
          axisPointer: {
            type: 'shadow'
          }
        },
        grid: {
          top:'3%',
          left: '3%',
          right: '4%',
          bottom: '10%',
          containLabel: true
        },
        xAxis: [
          {
            type: 'category',
            data: [],
            axisTick: {
              alignWithLabel: true
            }
          }
        ],
        yAxis: [
          {
            type: 'value'
          }
        ],
        series: [
          {
            name: 'Direct',
            type: 'bar',
            barWidth: '60%',
            data:[]
          }
        ]
      },

      //失效案例数据列表
      caseUseData: [{
        id: '1',//主键
        caseUse: '王小虎',//失效案例描述
        pictureList:'',//图片列表
        videoList:'',//视频列表
        editName:'',
        editDate:'',
        reserve1:'',
        reserve2:'',
        reserve3:''
      }],
      //用户编辑失效案例库的类型
      caseUseDoe:0,
      //用户点击的当前条目记录，是scope格式
      caseUseScope:null,
      //用户输入的失效案例信息
      inputTextCaseUse:'',

      //分页控制变量
      table_fileName_tab:'chinese',
      //控制作业指导书步骤的
      work_step_tab:'chinese',
      //控制忙加载的变量:用在了控制注意点的编辑
      work_problem_loading:false,
      //控制忙加载的变量：用在了控制作业指导书步骤的
      work_step_loading:false,
    }
  },
  methods: {
    //通用，翻译程序
    translate(doe){
      //作业指导书的注意点部分
      if (doe===1){
        if (this.pointsActiveTab==='chinese'){
          this.work_problem_loading=true
          translate_zh_en_ru(this.pointsChineseEditor.txt.html(),'zh',2).then(data=>{
            this.pointsEnglishEditor.txt.html(data.en)
            this.pointsRussianEditor.txt.html(data.ru)
            this.work_problem_loading=false
          })
        }
        else if (this.pointsActiveTab==='english') {
          //判断用户在那个tab上，确定是那个语言
          // 创建包含两个翻译请求的Promise数组
          // 中文翻译
          this.work_problem_loading = true
          translate_zh_en_ru(this.pointsEnglishEditor.txt.html(), 'en', 2).then(data => {
            this.pointsRussianEditor.txt.html(data.ru)
            this.pointsChineseEditor.txt.html(data.zh)
            this.work_problem_loading = false
          })
        }
        else if (this.pointsActiveTab==='russian'){
          this.work_problem_loading=true
          //判断用户在那个tab上，确定是那个语言
          translate_zh_en_ru(this.pointsRussianEditor.txt.html(), 'ru', 2).then(data => {
            this.pointsEnglishEditor.txt.html(data.en)
            this.pointsChineseEditor.txt.html(data.zh)
            this.work_problem_loading = false
          })
        }
      }
      //作业指导书中步骤的翻译
      else if (doe===2){
        if (this.pointsActiveTab==='chinese'){
          this.work_problem_loading=true
          translate_zh_en_ru(this.inputText1,'zh',1).then(data=>{
            this.inputTextEnglish1=data.en
            this.inputTextRussian1=data.ru
            this.work_problem_loading=false
          })
        }
        else if (this.pointsActiveTab==='english') {
          //判断用户在那个tab上，确定是那个语言
          // 创建包含两个翻译请求的Promise数组
          // 中文翻译
          this.work_problem_loading = true
          translate_zh_en_ru(this.inputTextEnglish1, 'en', 1).then(data => {
            this.inputText1=data.zh
            this.inputTextRussian1=data.ru
            this.work_problem_loading = false
          })
        }
        else if (this.pointsActiveTab==='russian'){
          this.work_problem_loading=true
          //判断用户在那个tab上，确定是那个语言
          translate_zh_en_ru(this.inputTextRussian1, 'ru', 1).then(data => {
            this.inputText1=data.zh
            this.inputTextEnglish1=data.en
            this.work_problem_loading = false
          })
        }
      }
      //作业指导书中品质关注点
      else if (doe===3){
        if (this.pointsActiveTab==='chinese'){
          this.work_problem_loading=true
          translate_zh_en_ru(this.qualityCheckChineseEditor.txt.html(),'zh',2).then(data=>{
            this.qualityCheckEnglishEditor.txt.html(data.en)
            this.qualityCheckRussianEditor.txt.html(data.ru)
            this.work_problem_loading=false
          })
        }
        else if (this.pointsActiveTab==='english') {
          //判断用户在那个tab上，确定是那个语言
          // 创建包含两个翻译请求的Promise数组
          // 中文翻译
          this.work_problem_loading = true
          translate_zh_en_ru(this.qualityCheckEnglishEditor.txt.html(), 'en', 2).then(data => {
            this.qualityCheckRussianEditor.txt.html(data.ru)
            this.qualityCheckEnglishEditor.txt.html(data.zh)
            this.work_problem_loading = false
          })
        }
        else if (this.pointsActiveTab==='russian'){
          this.work_problem_loading=true
          //判断用户在那个tab上，确定是那个语言
          translate_zh_en_ru(this.pointsRussianEditor.txt.html(), 'ru', 2).then(data => {
            this.pointsEnglishEditor.txt.html(data.en)
            this.pointsChineseEditor.txt.html(data.zh)
            this.work_problem_loading = false
          })
        }
      }
      //作业指导书中步骤的工具、辅料等翻译
      else if (doe===4){
        if (this.pointsActiveTab==='chinese'){
          //去翻译辅料的内容
          this.work_problem_loading=true
          translate_zh_en_ru(this.inputText4,'zh',1).then(data=>{
            this.inputTextEnglish4=data.en
            this.inputTextRussian4=data.ru
            this.work_problem_loading=false
          })
          translate_zh_en_ru(this.inputText5,'zh',1).then(data=>{
            this.inputTextEnglish5=data.en
            this.inputTextRussian5=data.ru
            this.work_problem_loading=false
          })
          translate_zh_en_ru(this.inputText6,'zh',1).then(data=>{
            this.inputTextEnglish6=data.en
            this.inputTextRussian6=data.ru
            this.work_problem_loading=false
          })
        }
        else if (this.pointsActiveTab==='english') {
          //判断用户在那个tab上，确定是那个语言
          // 创建包含两个翻译请求的Promise数组
          // 中文翻译
          this.work_problem_loading = true
          translate_zh_en_ru(this.inputTextEnglish4, 'en', 1).then(data => {
            this.inputText4=data.zh
            this.inputTextRussian4=data.ru
            this.work_problem_loading = false
          })
          translate_zh_en_ru(this.inputTextEnglish5, 'en', 1).then(data => {
            this.inputText5=data.zh
            this.inputTextRussian5=data.ru
            this.work_problem_loading = false
          })
          translate_zh_en_ru(this.inputTextEnglish6, 'en', 1).then(data => {
            this.inputText6=data.zh
            this.inputTextRussian6=data.ru
            this.work_problem_loading = false
          })
        }
        else if (this.pointsActiveTab==='russian'){
          this.work_problem_loading=true
          //判断用户在那个tab上，确定是那个语言
          translate_zh_en_ru(this.inputTextRussian4, 'ru', 1).then(data => {
            this.inputText4=data.zh
            this.inputTextEnglish4=data.en
            this.work_problem_loading = false
          })
          translate_zh_en_ru(this.inputTextRussian5, 'ru', 1).then(data => {
            this.inputText5=data.zh
            this.inputTextEnglish5=data.en
            this.work_problem_loading = false
          })
          translate_zh_en_ru(this.inputTextRussian6, 'ru', 1).then(data => {
            this.inputText6=data.zh
            this.inputTextEnglish6=data.en
            this.work_problem_loading = false
          })
        }
      }
    },
    //通用，树形导航筛选
    filterNode(value, data) {
      if (!value) return true;
      return data.label.indexOf(value) !== -1;
    },
    //通用，退出登录
    logOut(){
      localStorage.removeItem('u_token');
      localStorage.removeItem('userName')
      this.$router.push('UserLogin')
    },
    //通用，把当前日期组合为YYYY-MM-DD格式的文本格式
    nowDateStr() {
      const now = new Date(); // 获取当前日期

      const year = now.getFullYear(); // 获取年份
      const month = String(now.getMonth() + 1).padStart(2, '0'); // 获取月份，注意月份从0开始，需要加1，并确保是两位数
      const day = String(now.getDate()).padStart(2, '0'); // 获取日期，并确保是两位数

      return `${year}-${month}-${day}`; // 返回格式化后的日期
    },
    //单击树形导航结构的反应
    treeClick(data,node) {
      this.titleMianId='未选择产品'
      this.titleMianOp='未选择工序'
      if (node.level>=3){
        this.treeData=data
        this.treeNode=node
        let firstFiledVal=''
        if (this.treeNode.parent.parent.label==='装配车间' ||
            this.treeNode.parent.parent.label==='Assembly workshop' ||
            this.treeNode.parent.parent.label==='Сборочная линия'){
          firstFiledVal='装配车间/Assembly workshop/Сборочная линия'
        }
        else if (this.treeNode.parent.parent.label==='机加车间' ||
            this.treeNode.parent.parent.label==='Machining workshop' ||
            this.treeNode.parent.parent.label==='Цех механической обработки'){
          firstFiledVal='机加/Machining Workshop/Обработки линия'}
        const secondFiledVal=node.parent.label
        const thirdFiledVal=node.data.label
        //向后端查询数据
        this.inquiryType('workshop','productId','op',firstFiledVal,secondFiledVal,thirdFiledVal).then(data=>{
          this.tableData=data
          //所有的内容清空
          this.workBook=[]
          this.partsListData=[]
          this.caseUseData=[]

        })
        this.tableDataScope=null
        this.tableDataTemp={
          //主键
          id: '',
          //车间名称
          workshop: '',
          //线体名称
          lineName: '',
          //工序名称
          op: '',
          //文件名称
          fileName: '',
          //版本号
          editionNum: '',
          //编制日期
          writeDate: '',
          //执行日期
          executeDate: '',
          //文件编号
          fileNum: '',
          //编制
          writeUse: '',
          //审核
          examineUse: '',
          //批准
          ratifyUse: '',
          //会签
          countersignUse: '',
          //作业指导书
          workBook: '',
          //产品图号
          productId: '',
          //视频附件
          bookVideo: '',
          //修改记录
          editRecord: '',
          //控制计划标记位
          controlSign: '',
          //三不检验指导书标记位
          threeBookSign: '',
          //装配零部件明细
          partsList: '',
          //指导书类型
          bookType: '',
          //删除标记位
          deleteSign: '',
          //创建时间
          establishTime: '',
          //修改时间
          UpdateTime: '',
        }
        //打开弹窗
        this.drawer=true
      }
    },
    //单击树形导航结构的反应,用在了关联已有的弹窗中
    treeClick1(data,node) {
      this.titleMianId='未选择产品'
      this.titleMianOp='未选择工序'
      if (node.level>=3){
        this.treeData=data
        this.treeNode=node
        let firstFiledVal=''
        if (this.treeNode.parent.parent.label==='装配车间' ||
            this.treeNode.parent.parent.label==='Assembly workshop' ||
            this.treeNode.parent.parent.label==='Сборочная линия'){
          firstFiledVal='装配车间/Assembly workshop/Сборочная линия'
        }
        else if (this.treeNode.parent.parent.label==='机加车间' ||
            this.treeNode.parent.parent.label==='Machining workshop' ||
            this.treeNode.parent.parent.label==='Цех механической обработки'){
          firstFiledVal='机加/Machining Workshop/Обработки линия'}
        const secondFiledVal=node.parent.label
        const thirdFiledVal=node.data.label
        //向后端查询数据
        this.inquiryType('workshop','productId','op',firstFiledVal,secondFiledVal,thirdFiledVal).then(data=>{
          this.tableDataCall=data
        })
        //打开弹窗
        this.drawerCall=true
      }
    },
    //通用，语言选择
    chooseLanguage(language){
      //需要在步骤内容部分显示出总的工时时间
      let workTime=0
      if (this.workBook.length>0){
        for (let i = 0; i < this.workBook.length; i++) {
          workTime=workTime+ Number(this.workBook[i].spendTime)
        }
      }

      this.languageS=language
      if (this.languageS==='chinese'){
        this.treeControl=tree_workshop_product_op_chinese
        this.treeList=this.treeListChinese
        this.main.cancel='取 消'
        this.main.ok='确 定'
        this.main.sureToClose='确认关闭？'
        this.main.sureToDelete='确定删除吗？'
        this.main.chinese='中文'
        this.main.english='英文'
        this.main.russian='俄文'
        this.main.qualityManagementSystem='俄动力质量管理系统'
        this.main.operationWorkInstruction='工序作业指导书'
        this.main.selectionPrompt='选择提示：'
        this.main.titleMianId='未选择产品'
        this.main.titleMianOp='未选择工序'
        this.main.filter='输入关键字进行过滤'
        this.main.information='表单信息'
        this.main.line='线体名称：'
        this.main.op='工序号：'
        this.main.verNoLatest='版本号：最新'
        this.main.dateOfPreparation='编制日期：'
        this.main.implementationDate='执行日期：'
        this.main.documentNo='文件编号：'
        this.main.preparedBy='编制：'
        this.main.checked='审核：'
        this.main.approve='批准：'
        this.main.page='会签：'
        this.main.noDataYet='暂无数据'
        this.main.picture='图片'
        this.main.video='视频'

        this.pageVal.instruction='要领书/指导书'
        this.pageVal.order='序号'
        this.pageVal.stepContent='步骤内容(时长：'+String(workTime)+'S)'
        this.pageVal.attentionPointsExplanation='注意点说明：'
        this.pageVal.qualityInspection='品质检查：'
        this.pageVal.controlPlanRequirements='控制计划要求：'
        this.pageVal.loadPreviousAssociations='加载以前关联'
        this.pageVal.processName='过程名称/操作描述'
        this.pageVal.device='机器、装置、夹具、工装'
        this.pageVal.characteristic='特性'
        this.pageVal.number='编号'
        this.pageVal.product='产品'
        this.pageVal.process='过程'
        this.pageVal.characteristicClassification='特殊特性分类'
        this.pageVal.method='方法'
        this.pageVal.tolerance='产品/过程规范/公差'
        this.pageVal.measure='评价/测量技术'
        this.pageVal.capacity='容量'
        this.pageVal.frequency='频率'
        this.pageVal.controlMethod='控制方法'
        this.pageVal.department='责任部门'
        this.pageVal.reaction='反应计划'
        this.pageVal.tools='工具：'
        this.pageVal.equipment='设备：'
        this.pageVal.accessories='辅料：'
        this.pageVal.startingSignal='起始信号：'
        this.pageVal.endSignal='结束信号：'
        this.pageVal.operationStep='操作步骤'
        this.pageVal.workTime='工步用时(单位s)'
        this.pageVal.focusPoint='关注点：'
        this.pageVal.partDetailsList='零部件明细'
        this.pageVal.add='新建'
        this.pageVal.diagramCode='图示代码'
        this.pageVal.stepNumber='工步号'
        this.pageVal.partName='零部件名称'
        this.pageVal.partNumber='零部件图号'
        this.pageVal.quantity='数量'
        this.pageVal.edit='编辑'
        this.pageVal.partName1='零件名称'
        this.pageVal.assemblyQuantity='装配数量'
        this.pageVal.additionalInformation='附加信息'
        this.pageVal.specialCharacteristics='特殊特性'
        this.pageVal.failureCase='失效案例库'
        this.pageVal.caseDescription='案例描述'
        this.pageVal.manHour='工时'
        this.pageVal.timeDistributionChart='时间分布图'
        this.pageVal.totalDuration='总时长：'
        this.pageVal.operator='操作人员'
        this.pageVal.employeeId='工号'
        this.pageVal.name='姓名'
        this.pageVal.startDate='开始日期'
        this.pageVal.employeeId1='工号：'
        this.pageVal.name1='姓名：'
        this.pageVal.startDate1='开始日期：'
        this.pageVal.assessmentLevel='考核等级：'
        this.pageVal.mentor='指导人：'
        this.pageVal.uploadImage='上传图片：'
        this.pageVal.workshop='车间名称'
        this.pageVal.drawingNumber='产品图号'
        this.pageVal.line='线体名称'
        this.pageVal.op='工序号'
        this.pageVal.verNo='版本号'
        this.pageVal.fileName='文件名称'
        this.pageVal.dateOfPreparation='编制日期'
        this.pageVal.implementationDate='执行日期'
        this.pageVal.designateRelevantPersonnel='指定相关人员'
        this.pageVal.preparedBy='编制人'
        this.pageVal.checked='审核人'
        this.pageVal.countersigned='会签人'
        this.pageVal.approve='批准人'
        this.pageVal.submitResult='提交结果'
        this.pageVal.invokeExisting='调用已有'
        this.pageVal.create='立即创建'
        this.pageVal.cancel='取消'
        this.pageVal.select='请选择'
        this.pageVal.selectTheDate='选择日期'
        this.pageVal.enter='输入内容'
        this.pageVal.enterQuantity='请输入数量'
        this.pageVal.separate='请输入内容,语言使用“|*|”符号分割'
        this.pageVal.specialCharacteristics1='特殊特性：'
        this.pageVal.selfCheckingProjects='自检项目'
        this.pageVal.project='项目'
        this.pageVal.requirement='检查要求'
      }
      else if (this.languageS==='english'){
        this.treeControl=tree_workshop_product_op_english
        this.treeList=this.treeListEnglish
        this.main.cancel='Cancel'
        this.main.ok='OK'
        this.main.sureToClose='Sure to close?'
        this.main.sureToDelete='Sure to delete?'
        this.main.chinese='Chinese'
        this.main.english='English'
        this.main.russian='Russian'
        this.main.qualityManagementSystem='Quality Management System'
        this.main.operationWorkInstruction='Operation Work Instruction'
        this.main.selectionPrompt='Selection prompt:'
        this.main.titleMianId='No Product Selected'
        this.main.titleMianOp='No Process Selected'
        this.main.filter='Filter'
        this.main.information='Information'
        this.main.line='Line:'
        this.main.op='OP：'
        this.main.verNoLatest='Ver. No: Latest'
        this.main.dateOfPreparation='Date of preparation:'
        this.main.implementationDate='Implementation date:'
        this.main.documentNo='Document No.:'
        this.main.preparedBy='Prepared by:'
        this.main.checked='Checked:'
        this.main.approve='Approve:'
        this.main.page='Countersigned:'
        this.main.noDataYet='No data yet'
        this.main.picture='Picture'
        this.main.video='Video'

        this.pageVal.instruction='Instruction'
        this.pageVal.order='Order'
        this.pageVal.stepContent='Step Content(Time：'+String(workTime)+'S)'
        this.pageVal.attentionPointsExplanation='Attention Points Explanation:'
        this.pageVal.qualityInspection='Quality Inspection:'
        this.pageVal.controlPlanRequirements='Control Plan Requirements:'
        this.pageVal.loadPreviousAssociations='Load previous associations'
        this.pageVal.processName='Process Name/ Operation Description'
        this.pageVal.device='Machine、Device、Fixture、Tooling'
        this.pageVal.characteristic='Characteristic'
        this.pageVal.number='Number'
        this.pageVal.product='Product'
        this.pageVal.process='Process'
        this.pageVal.characteristicClassification='Characteristic Classification'
        this.pageVal.method='Method'
        this.pageVal.tolerance='Product/ Process Specification/ Tolerance'
        this.pageVal.measure='Evaluation/ Measurement Technique'
        this.pageVal.capacity='Capacity'
        this.pageVal.frequency='Frequency'
        this.pageVal.controlMethod='Control Method'
        this.pageVal.department='Department'
        this.pageVal.reaction='Reaction Plan'
        this.pageVal.tools='Tools:'
        this.pageVal.equipment='Equipment:'
        this.pageVal.accessories='Accessories:'
        this.pageVal.startingSignal='Starting signal:'
        this.pageVal.endSignal='End signal:'
        this.pageVal.operationStep='Operation step:'
        this.pageVal.workTime='Work time(s)'
        this.pageVal.focusPoint='Focus point:'
        this.pageVal.partDetailsList='Part Details List'
        this.pageVal.add='Add'
        this.pageVal.diagramCode='Diagram Code'
        this.pageVal.stepNumber='Step Number'
        this.pageVal.partName='Part Name'
        this.pageVal.partNumber='Part Number'
        this.pageVal.quantity='Quantity'
        this.pageVal.edit='Edit'
        this.pageVal.partName1='Part name'
        this.pageVal.assemblyQuantity='Assembly quantity'
        this.pageVal.additionalInformation='Additional information'
        this.pageVal.specialCharacteristics='Special Characteristics'
        this.pageVal.failureCase='Failure Case'
        this.pageVal.caseDescription='Case Description'
        this.pageVal.manHour='Man-hour'
        this.pageVal.timeDistributionChart='Time distribution chart'
        this.pageVal.totalDuration='Total duration:'
        this.pageVal.operator='Operator'
        this.pageVal.employeeId='Employee ID'
        this.pageVal.name='Name'
        this.pageVal.startDate='Start date'
        this.pageVal.employeeId1='Employee ID:'
        this.pageVal.name1='Name:'
        this.pageVal.startDate1='Start date:'
        this.pageVal.assessmentLevel='Assessment level:'
        this.pageVal.mentor='Mentor:'
        this.pageVal.uploadImage='Upload image:'
        this.pageVal.workshop='Workshop'
        this.pageVal.drawingNumber='Drawing number'
        this.pageVal.line='Line'
        this.pageVal.op='OP'
        this.pageVal.verNo='Ver. No'
        this.pageVal.fileName='File name'
        this.pageVal.dateOfPreparation='Date of preparation'
        this.pageVal.implementationDate='Implementation date'
        this.pageVal.designateRelevantPersonnel='Designate relevant personnel'
        this.pageVal.preparedBy='Prepared by'
        this.pageVal.checked='Checked'
        this.pageVal.countersigned='Countersigned'
        this.pageVal.approve='Approve'
        this.pageVal.submitResult='Submit result'
        this.pageVal.invokeExisting='Invoke existing'
        this.pageVal.create='Create now'
        this.pageVal.cancel='Cancel'
        this.pageVal.select='Select'
        this.pageVal.selectTheDate='Select the date'
        this.pageVal.enter='Enter'
        this.pageVal.enterQuantity='Enter quantity'
        this.pageVal.separate='Please enter the content and use the symbol \' | * |\' to separate the language'
        this.pageVal.specialCharacteristics1='Special Characteristics:'
        this.pageVal.selfCheckingProjects='Self checking projects'
        this.pageVal.project='Project'
        this.pageVal.requirement='Check requirements'
      }
      else if (this.languageS==='russian'){
        this.treeControl=tree_workshop_product_op_russian
        this.treeList=this.treeListRussian
        this.main.cancel='Отмена'
        this.main.ok='Подтвердить'
        this.main.sureToClose='Уверен в закрытии?'
        this.main.sureToDelete='Уверен в удалении данных?'
        this.main.chinese='Китайский'
        this.main.english='Aнглийский'
        this.main.russian='Русский'
        this.main.qualityManagementSystem='Cистема yправления качества'
        this.main.operationWorkInstruction='Инструкция по работе'
        this.main.selectionPrompt='Выбор:'
        this.main.titleMianId='Нет выбранного продукта'
        this.main.titleMianOp='Не выбран процесс'
        this.main.filter='Фильтр'
        this.main.information='Информация'
        this.main.line='Лине:'
        this.main.op='Oперации:'
        this.main.verNoLatest='Номер версии: последний'
        this.main.dateOfPreparation='Дата разработки:'
        this.main.implementationDate='Дата внедрения:'
        this.main.documentNo='Номер документа:'
        this.main.preparedBy='Кем разработан:'
        this.main.checked='Проверено:'
        this.main.approve='Одобрено:'
        this.main.page='Подписано:'
        this.main.noDataYet='Нет данных'
        this.main.picture='Изображение'
        this.main.video='Видео'

        this.pageVal.instruction='Инструкция'
        this.pageVal.order='Заказ'
        this.pageVal.stepContent='Содержание шага(Time：'+String(workTime)+'S)'
        this.pageVal.attentionPointsExplanation='Объяснение пунктов внимания:'
        this.pageVal.qualityInspection='Инспекция качества:'
        this.pageVal.controlPlanRequirements='Требования плана управления:'
        this.pageVal.loadPreviousAssociations='Загрузить предыдущие ассоциации'
        this.pageVal.processName='Имя процесса/ Описание операции'
        this.pageVal.device='Машина、Устройство、Инструмент'
        this.pageVal.characteristic='Характеристика'
        this.pageVal.number='Номер'
        this.pageVal.product='Продукт'
        this.pageVal.process='Процесс'
        this.pageVal.characteristicClassification='Характеристическая классификация'
        this.pageVal.method='Метод'
        this.pageVal.tolerance='Продукт/ Спецификация процесса/ Толерантность'
        this.pageVal.measure='Оценка/ Техника измерения'
        this.pageVal.capacity='Емкость'
        this.pageVal.frequency='Частота'
        this.pageVal.controlMethod='Метод контроля'
        this.pageVal.department='Департамент'
        this.pageVal.reaction='План реакции'
        this.pageVal.tools='Инструменты:'
        this.pageVal.equipment='Оборудование:'
        this.pageVal.accessories='Аксессуары:'
        this.pageVal.startingSignal='Начальный сигнал:'
        this.pageVal.endSignal='Конечный сигнал:'
        this.pageVal.operationStep='Шаг работы:'
        this.pageVal.workTime='Время работы(Секунда)'
        this.pageVal.focusPoint='Фокусная точка:'
        this.pageVal.partDetailsList='Список части'
        this.pageVal.add='Добавить'
        this.pageVal.diagramCode='Код диаграммы'
        this.pageVal.stepNumber='Номер шага'
        this.pageVal.partName='Название части'
        this.pageVal.partNumber='Номер детали'
        this.pageVal.quantity='Количество'
        this.pageVal.edit='Редактировать'
        this.pageVal.partName1='Название части'
        this.pageVal.assemblyQuantity='Количество сборки'
        this.pageVal.additionalInformation='Дополнительная информация'
        this.pageVal.specialCharacteristics='Особые характеристики'
        this.pageVal.failureCase='Случай неудачи'
        this.pageVal.caseDescription='Описание дела'
        this.pageVal.manHour='Рабочее время'
        this.pageVal.timeDistributionChart='График распределения времени'
        this.pageVal.totalDuration='Общая продолжительность:'
        this.pageVal.operator='Оператор'
        this.pageVal.employeeId='ID сотрудника'
        this.pageVal.name='Имя'
        this.pageVal.startDate='Дата начала'
        this.pageVal.employeeId1='ID сотрудника:'
        this.pageVal.name1='Имя:'
        this.pageVal.startDate1='Дата начала:'
        this.pageVal.assessmentLevel='Уровень оценки:'
        this.pageVal.mentor='Ментор:'
        this.pageVal.uploadImage='Загрузить изображение:'
        this.pageVal.workshop='Цех'
        this.pageVal.drawingNumber='Номер рисунка'
        this.pageVal.line='Линия'
        this.pageVal.op='Операция'
        this.pageVal.verNo='Номер версии'
        this.pageVal.fileName='Имя файла'
        this.pageVal.dateOfPreparation='Дата разработки'
        this.pageVal.implementationDate='Дата внедрения'
        this.pageVal.designateRelevantPersonnel='Назначение соответствующего персонала'
        this.pageVal.preparedBy='Кем разработан'
        this.pageVal.checked='Проверено'
        this.pageVal.countersigned='Подписано'
        this.pageVal.approve='Одобрено'
        this.pageVal.submitResult='Отправить результат'
        this.pageVal.invokeExisting='Вызвать существующее'
        this.pageVal.create='Cоздать сейчас'
        this.pageVal.cancel='Oтменить'
        this.pageVal.select='Выбрать'
        this.pageVal.selectTheDate='Выберите дату'
        this.pageVal.enter='Введите'
        this.pageVal.enterQuantity='Введите количество'
        this.pageVal.separate='Пожалуйста, введите содержание и используйте символ \' | * |\' для разделения языка'
        this.pageVal.specialCharacteristics1='Особые характеристики:'
        this.pageVal.selfCheckingProjects='Проекты самопроверки'
        this.pageVal.project='Проект'
        this.pageVal.requirement='Требования к проверке'
      }
    },
    //通用：语言中备注一部分信息的统一变化函数:1.用在了体现总工时的地方
    LanguageChange(){
      //需要在步骤内容部分显示出总的工时时间
      let workTime=0
      if (this.workBook.length>0){
        for (let i = 0; i < this.workBook.length; i++) {
          workTime=workTime+ Number(this.workBook[i].spendTime)
        }
      }
      if (this.languageS==='chinese'){
        this.pageVal.stepContent='步骤内容(时长：'+String(workTime)+'S)'
      }
      else if (this.languageS==='english'){
        this.pageVal.stepContent='Step Content(Time：'+String(workTime)+'S)'
      }
      else if (this.languageS==='russian'){
        this.pageVal.stepContent='Содержание шага(Time：'+String(workTime)+'S)'
      }

    },
    //通用：误关闭弹窗的确认函数(中英俄)
    getI18nText(key) {
      const i18nMessages = {
        chinese: {
          confirmClose: '确认关闭？',
          confirmButton: '确定',
          cancelButton: '取消',
        },
        english: {
          confirmClose: 'Sure to close?',
          confirmButton: 'OK',
          cancelButton: 'Cancel',
        },
        russian: {
          confirmClose: 'Уверен в закрытии?',
          confirmButton: 'Подтвердить',
          cancelButton: 'Отмена',
        },
      };
      return i18nMessages[this.languageS]?.[key] ?? i18nMessages.chinese[key];
    },
    handleClose(done) {
      this.$confirm(
          this.getI18nText('confirmClose'), // 消息内容
          {
            confirmButtonText: this.getI18nText('confirmButton'), // 确认按钮
            cancelButtonText: this.getI18nText('cancelButton'),    // 取消按钮
          }
      )
          .then(() => done())
          .catch(() => {});
    },

    //单击控制计划的树形导航结构
    controlTreeClick(data,node){
      if (node.level===3){
        this.thirdTree=data.label
        this.secondTree=node.parent.label
        this.firstTree=node.parent.parent.label
        let workshop=''
        if (this.firstTree==='装配车间' || this.firstTree==='Assembly Workshop' ||this.firstTree==='Сборочная линия'){
          workshop='装配/Assembly Workshop/Сборочная линия'
        }
        else if (this.firstTree==='机加车间' || this.firstTree==='Machining Workshop' ||this.firstTree==='Обработки линия'){
          workshop='机加/Machining Workshop/Обработки линия'
        }
        //查询出新的控制计划
        this.queryThreeFieldControlPlan('workshop',workshop,'drawing',this.secondTree, 'op',this.thirdTree).then(data=>{
          this.tableDataControl=data
        })
      }
    },
    //在增加一个作业指导书的时候，调用已有的作业指导书，可以在这个上修改
    callExisting(){
      //打开弹窗
      this.tableDataCall=[]
      this.drawerCall=true

    },
    //查询用户信息的函数
    inquiry(){
      //输入用户编号，向后端查询信息
      const useId=localStorage.getItem('userName').replace(/"/g, '');
      this.$request.post('/useQueryPower',{
        queryFiledName:'operateGuideBook',
        userId:useId,
      }).then(result=>{
        if (result.code === 401) {
          this.$router.push('UserLogin')
          alert("您未登录，请登录")
        }else {
          this.useName=result.data.name
          this.usePower=result.data.operateGuideBook
          this.useId=useId
        }
      })
    },
    //点击操作人员的编辑按钮，进行弹窗的函数
    operatorListEditShow(doe,scope){
      if (this.tableDataScope===null || this.tableDataScope==='' || this.tableDataScope===undefined){
        this.$message.warning("请选择作业指导书")
        return
      }
      this.operatorListDoe=doe
      this.operatorListScope=scope
      //是向下插入
      if (doe===1){
        //初始值清空
        this.operatorListForm={
          //主键
              id:'',
              //工号
              operator_id:'',
              //姓名
              operator_name:'',
              //开始时间
              star_time:'',
              //技能等级
              skill_level:'1/4',
              //指导姓名人
              mentor:'',
              //人员照片
              operator_path:'',
              //预留
              reserved1:'',
              reserved2:'',
              reserved3:'',
              reserved4:'',
              reserved5:'',
        }
        this.operatorListImageUrl=null
        //打开弹窗
        this.operatorDialog=true
      }
      //是编辑
      else if (doe===2){
        //给表单赋值
        this.operatorListForm=_.cloneDeep(scope.row)
        //组合文件信息，形成一个文件
        this.operatorListFile=null
        this.operatorListImageUrl=filepath+this.operatorListForm.operator_path
        console.log(this.tableDataScope.row.id)
        //打开弹窗
        this.operatorDialog=true
      }
    },
    //点击操作人员的编辑弹窗，点击确定按钮
    operatorListEdit(){
      //数据校验
      if (this.operatorListForm.operator_name==='' || this.operatorListForm.operator_name===null || this.operatorListForm.operator_name===undefined){
        this.$message.error('操作者姓名没有填写')
        return
      }
      if (this.operatorListForm.mentor==='' || this.operatorListForm.mentor===null || this.operatorListForm.mentor===undefined){
        this.$message.error('指导者姓名没有填写')
        return
      }
      if (this.operatorListForm.star_time==='' || this.operatorListForm.star_time===null || this.operatorListForm.star_time===undefined){
        this.$message.error('开始时间没有填写')
        return
      }
      //是向下插入
      if (this.operatorListDoe===1){
        //处理文件
        if (this.operatorListFile!==null){
          //给图片赋值一个唯一的名字
          let fileName=this.generateUniqueId()+'.'+this.operatorListFile.name.split('.')[this.operatorListFile.name.split('.').length-1]
          //给图片文件的名字复制
          this.operatorListFile.name=fileName
          //给表单的图片路径名称赋值
          this.operatorListForm.operator_path=fileName
          //组合数据
          let operatorListTemp=_.cloneDeep(this.operatorList)
          operatorListTemp.push(this.operatorListForm)
          let str=''
          for (let i = 0; i < operatorListTemp.length; i++) {
            operatorListTemp[i].id=i+1
            //组合数据
            let temp= Object.values(operatorListTemp[i]).join('|%|')
            if (i===0){
              str=temp
            }
            else {
              str=str+'|-|'+temp
            }
          }
          //向后端发送，需要用传输文件的接口
          const formData = new FormData();
          formData.append('file', this.operatorListFile.raw)
          formData.append('fieldName','operator')
          formData.append('fieldVal',str)
          formData.append('fileName',this.operatorListFile.name)
          formData.append('id',this.tableDataScope.row.id)
          //状态码，0：代表新增；1:代表删除老的，加入新的；即新的替换老的；3：删除老的；
          formData.append('type',0)
          //老文件的文件名称
          formData.append('oldFileName','')
          this.$requestFile.post('/editOperatorOperateGuideBook',formData).then(result=>{
            if (result.code === 401) {
              this.$router.push('UserLogin')
              alert("您未登录，请登录")
            }
            else {
              //修改大表数据
              this.tableData[this.tableDataScope.$index].operator=str
              //修改scope数据
              this.tableDataScope.row.operator= str
              //修改operatorList数据
              this.operatorList.push(this.operatorListForm)
            }
          })
        }
        else {
          //组合数据，用不是文件的接口修改数据
          //组合数据
          let operatorListTemp=_.cloneDeep(this.operatorList)
          operatorListTemp.push(this.operatorListForm)
          let str=''
          for (let i = 0; i < operatorListTemp.length; i++) {
            operatorListTemp[i].id=i+1
            //组合数据
            let temp= Object.values(operatorListTemp[i]).join('|%|')
            if (i===0){
              str=temp
            }
            else {
              str=str+'|-|'+temp
            }
          }
          //向后端发送请求，修改一个字段
          this.$request.post('operateGuideBookOneFiledById',{
            id:this.tableDataScope.row.id,
            filedName:'operator',
            filedVal:str,
          })
              .then(result=>{
                if (result.code === 401) {
                  this.$router.push('UserLogin')
                  alert("您未登录，请登录")
                }
                else {
                  //修改大表数据
                  this.tableData[this.tableDataScope.$index].operator=str
                  //修改scope数据
                  this.tableDataScope.row.operator= str
                  //修改operatorList数据
                  this.operatorList.push(this.operatorListForm)
                  this.operatorDialog=false
                }
              })
        }
      }
      else if (this.operatorListDoe===2){
        //如果文件没有修改
        if (this.operatorListImageUrl.includes(this.operatorListScope.row.operator_path)){
          console.log(this.operatorListFile,'文件没有修改')
          //只是修改文本，直接组合，去后端进行修改
          //组合数据，用不是文件的接口修改数据
          //组合数据
          let operatorListTemp=_.cloneDeep(this.operatorList)
          operatorListTemp.splice(this.operatorListScope.$index,1,this.operatorListForm)
          let str=''
          for (let i = 0; i < operatorListTemp.length; i++) {
            operatorListTemp[i].id=i+1
            //组合数据
            let temp= Object.values(operatorListTemp[i]).join('|%|')
            if (i===0){
              str=temp
            }
            else {
              str=str+'|-|'+temp
            }
          }
          //向后端发送请求，修改一个字段
          this.$request.post('operateGuideBookOneFiledById',{
            id:this.tableDataScope.row.id,
            filedName:'operator',
            filedVal:str,
          })
              .then(result=>{
                if (result.code === 401) {
                  this.$router.push('UserLogin')
                  alert("您未登录，请登录")
                }
                else {
                  //修改大表数据
                  this.tableData[this.tableDataScope.$index].operator=str
                  //修改scope数据
                  this.tableDataScope.row.operator= str
                  //修改operatorList数据
                  this.operatorList.splice(this.operatorListScope.$index,1,this.operatorListForm)
                  this.operatorDialog=false
                }
              })
        }
        //文件修改了
        else {
          //图片文件修改了，向后端走端口，类型是1；
          //给图片赋值一个唯一的名字
          let fileName=this.generateUniqueId()+'.'+this.operatorListFile.name.split('.')[this.operatorListFile.name.split('.').length-1]
          //组合数据
          let operatorListTemp=_.cloneDeep(this.operatorList)
          //给图片文件的名字赋值给文件
          this.operatorListFile.name=fileName
          //给表单的图片路径名称赋值（保存原有的Form中还是老的图片名称）
          let oldFileName=this.operatorListForm.operator_path
          this.operatorListForm.operator_path=fileName
          operatorListTemp.splice(this.operatorListScope.$index,1,this.operatorListForm)
          let str=''
          for (let i = 0; i < operatorListTemp.length; i++) {
            operatorListTemp[i].id=i+1
            //组合数据
            let temp= Object.values(operatorListTemp[i]).join('|%|')
            if (i===0){
              str=temp
            }
            else {
              str=str+'|-|'+temp
            }
          }
          //向后端发送，需要用传输文件的接口
          const formData = new FormData();
          formData.append('file', this.operatorListFile.raw)
          formData.append('fieldName','operator')
          formData.append('fieldVal',str)
          formData.append('fileName',this.operatorListFile.name)
          formData.append('id',this.tableDataScope.row.id)
          //状态码，0：代表新增；1:代表删除老的，加入新的；即新的替换老的；3：删除老的；
          formData.append('type',1)
          //老文件的文件名称
          formData.append('oldFileName',oldFileName)
          this.$requestFile.post('/editOperatorOperateGuideBook',formData).then(result=>{
            if (result.code === 401) {
              this.$router.push('UserLogin')
              alert("您未登录，请登录")
            }
            else {
              //修改大表数据
              this.tableData[this.tableDataScope.$index].operator=str
              //修改scope数据
              this.tableDataScope.row.operator= str
              //修改operatorList数据
              this.operatorList.splice(this.operatorListScope.$index,1,this.operatorListForm)
              //修改图片列表
              this.itemView=[]
              this.itemView.push(filepath+this.operatorListForm.operator_path)
              this.operatorDialog=false
            }
          })
        }
        }
      },
    //在操作人员的列表行上单击，组合出图片来
    operatorRowClick(row){
      //组合图片
      //组合走马灯的照片
      if (row.operator_path==='' || row.operator_path===undefined || row.operator_path===null){
        this.itemView=[]
      }
      else {
        this.itemView=[]
        this.itemView.push(filepath+row.operator_path)
      }
    },

    //辅助函数，依据用户现点击的是那个产品，那一序，那个车间，然后赛选出作业指导书，是用三个变量筛选产品的
    // val是一个joson格式的数据{firstFiledName：firstFiledName,
    async inquiryType(firstFiledName, secondFiledName, thirdFiledName, firstFiledVal, secondFiledVal, thirdFiledVal) {
      //向后端发送请求，把查询出来的作业指导书类别赋值给大表。
      const result = await this.$request.post('/inquiryOperateGuideBook', {
        firstFiledName: firstFiledName,
        secondFiledName: secondFiledName,
        thirdFiledName: thirdFiledName,
        firstFiledVal: firstFiledVal,
        secondFiledVal: secondFiledVal,
        thirdFiledVal: thirdFiledVal
      })
        if (result.code === 401) {
          this.$router.push('UserLogin')
          alert("您未登录，请登录")
        } else {
          return result.data
        }
    },
    // 辅助函数，调用所有的作业指导书
    async inquiryAllBook(){
      //向后端发送请求，把查询出来的作业指导书类别赋值给大表。
      const result = await this.$request.post('/inquiryOperateGuideBookAll')
      if (result.code === 401) {
        this.$router.push('UserLogin')
        alert("您未登录，请登录")
      } else {
        // 按照 op 升序排序
        result.data.sort((a, b) => a.op.localeCompare(b.op))
        return result.data
      }
    },
    //选择器的变化引起的函数
    selectChange(val){
      if (val==='机加车间/Machining workshop/Машиностроительный цех'){
        this.disabledLineName=false
      }
      else if (val==='装配车间/Assembly workshop/Сборочная линия'){
        this.disabledLineName=false
      }
    },
    //编辑表头的函数，有：1：增加；2：修改；3：删除
    editTable(doe){
      if (this.treeNode===null){
        alert("请先选择工序")
        return
      }

        //做的是工序业指导书,
        //把用户选择的是编辑/添加/删除  中的哪一项传递出去
        this.editTableUse=doe
        if (doe===1){
          //是插入操作，组合数据
          this.formTableData={
            //主键
            id:'',
            //车间名称
            workshop:'',
            //线体名称
            lineName:'',
            //工序名称
            op:'',
            //文件名称
            fileName:'',
            //版本号
            editionNum:'',
            //编制日期
            writeDate:'',
            //执行日期
            executeDate:'',
            //文件编号
            fileNum:'',
            //编制
            writeUse:'',
            //审核
            examineUse:'',
            //批准
            ratifyUse:'',
            //会签
            countersignUse:'',
            //作业指导书
            workBook:'',
            //产品图号
            productId:'',
            //视频附件
            BookVideo:'',
            //修改记录
            editRecord:'',
            //控制计划标记位
            controlSign:'',
            //三不检验指导书标记位
            threeBookSign:'',
            //装配零部件明细
            partsList:'',
            //指导书类型
            bookType:'装配作业指导书',
            //删除标记位
            deleteSign:'',
            //创建时间
            establishTime:'',
            //修改时间
            UpdateTime:'',
          }
          if (this.treeNode.parent.parent.label==='装配车间' ||
              this.treeNode.parent.parent.label==='Assembly workshop' ||
              this.treeNode.parent.parent.label==='Сборочная линия'){
            this.formTableData.workshop='装配车间/Assembly workshop/Сборочная линия'
            this.formTableData.op=this.treeNode.data.label
            this.formTableData.productId=this.treeNode.parent.label
            this.disabledLineName=false
            this.titleUse='您正在插入一行《作业指导书》'
            this.dialogTableHeader=true
          }
          else if (this.treeNode.parent.parent.label==='机加车间' ||
              this.treeNode.parent.parent.label==='Machining workshop' ||
              this.treeNode.parent.parent.label==='Цех механической обработки'){
            this.formTableData.workshop='机加/Machining Workshop/Обработки линия'
            this.formTableData.op=this.treeNode.data.label
            this.formTableData.productId=this.treeNode.parent.label
            this.disabledLineName=false
            this.titleUse='您正在插入一行《作业指导书》'
            this.dialogTableHeader=true
          }
        }
        else if (doe===2){
          if (this.workBook.length===0){
            alert("请选择一个指导书进行修改")
          }
          else {
            //是编辑工作，涉及到一个赋值，需要深度拷贝
            this.formTableData=_.cloneDeep(this.tableDataTemp)
            this.titleUse='您正在修改选择的《装配作业指导书》'
            //打开弹窗
            this.dialogTableHeader=true
          }
        }
        else if (doe===3){
          if (this.workBook.length===0){
            alert("请选择一个指导书进行修改")
          }
          else {
            //是删除，涉及到一个赋值，需要深度拷贝
            this.formTableData=_.cloneDeep(this.tableDataTemp)
            this.titleUse='您正在删除一个《装配作业指导书》'
            //打开弹窗
            this.dialogTableHeader=true
          }
        }


    },
    //表头弹窗中的确认的按钮，向后端保存数据
    onSubmit(doe,formName) {
      this.$refs[formName].validate((valid) => {
        if (valid) {
            //现在是对装配作业指导书进行添加/修改/删除,doe接收的是用户现在了操作类型：1.插入；2.编辑；3.删除
            if (doe===1){
              //现在是新建一个指导书
              /*组合数据*/
              //组合相关人员的标记
              this.formTableData.ratifyUse=this.formTableData.ratifyUse+'/指定'
              this.formTableData.examineUse=this.formTableData.examineUse+'/指定'
              this.formTableData.countersignUse=this.formTableData.countersignUse+'/指定'
              //组合两个时间的数据，编制时间，执行时间
              let date=new Date(this.formTableData.writeDate)
              let year = date.getFullYear().toString().padStart(4, '0');
              let month = (date.getMonth() + 1).toString().padStart(2, '0'); // 月份从0开始，所以需要+1
              let day = date.getDate().toString().padStart(2, '0');
              this.formTableData.writeDate=`${year}-${month}-${day}`

              date=new  Date(this.formTableData.executeDate)
              year = date.getFullYear().toString().padStart(4, '0');
              month = (date.getMonth() + 1).toString().padStart(2, '0'); // 月份从0开始，所以需要+1
              day = date.getDate().toString().padStart(2, '0');
              this.formTableData.executeDate=`${year}-${month}-${day}`

              //固定版本号，限定为1
              this.formTableData.editionNum=1
              //组合编制人
              this.formTableData.writeUse=this.useName
              //组合删除标记位
              this.formTableData.deleteSign=1
              if (this.formTableData.workBook==='' || this.formTableData.workBook===undefined || this.formTableData.workBook===null){
                //组合作业指导书的内容
                this.formTableData.workBook='作业指导书步骤|*|Steps of homework instruction manual|*|Этапы руководства по оперативной деятельности|%|作业关注点|*|Homework focus points|*|Приоритеты домашних заданий|%|品质检查|*|Quality Inspection|*|Контроль качества|%|0|%|-1|%|工具|*|tool|*|Инструменты|%|辅料|*|accessories|*|Вспомогательные материалы|%|设备|*|device|*|Оборудование|%|undefined|*||%|undefined|*||%|no|%|no|-|'
              }
              //向后端发送请求，插入数据
              this.$request.post('interOperateGuideBook',this.formTableData).then(result=>{
                if (result.code === 401) {
                  this.$router.push('UserLogin')
                  alert("您未登录，请登录")
                } else {
                  this.$message.success('插入成功')
                  //进行数据赋值(改造，改造成重新去查询本序的数据，调出有id的信息
                  this.inquiryType('workshop','productId','op',this.formTableData.workshop,this.formTableData.productId,this.formTableData.op).then(data=>{
                    this.tableData=data
                    //清空页面，提示用户需要重新选择作业指导书
                    this.workBook=[]
                    this.itemView=[]
                    this.itemViewVideo=[]
                    this.$message.success('请重新选择指导书')

                    this.dialogTableHeader=false
                  })
                }
              })
            }
            else if (doe===2){
              //是编辑操作
              /*组合数据*/
              //组合相关人员的标记,重新设定编审批的内容
              this.formTableData.ratifyUse=this.formTableData.ratifyUse.replace(/\/指定/g,'')
              this.formTableData.examineUse=this.formTableData.examineUse.replace(/\/指定/g,'')
              this.formTableData.countersignUse=this.formTableData.countersignUse.replace(/\/指定/g,'')
              this.formTableData.ratifyUse=this.formTableData.ratifyUse+'/指定'
              this.formTableData.examineUse=this.formTableData.examineUse+'/指定'
              this.formTableData.countersignUse=this.formTableData.countersignUse+'/指定'
              //组合两个时间的数据，编制时间，执行时间
              let date=new Date(this.formTableData.writeDate)
              let year = date.getFullYear().toString().padStart(4, '0');
              let month = (date.getMonth() + 1).toString().padStart(2, '0'); // 月份从0开始，所以需要+1
              let day = date.getDate().toString().padStart(2, '0');
              this.formTableData.writeDate=`${year}-${month}-${day}`

              date=new  Date(this.formTableData.executeDate)
              year = date.getFullYear().toString().padStart(4, '0');
              month = (date.getMonth() + 1).toString().padStart(2, '0'); // 月份从0开始，所以需要+1
              day = date.getDate().toString().padStart(2, '0');
              this.formTableData.executeDate=`${year}-${month}-${day}`

              //固定版本号，限定为1
              this.formTableData.editionNum=1
              //组合编制人
              this.formTableData.writeUse=this.useName

              this.$request.post('/editOperateGuideBookTable',this.formTableData).then(result=>{
                if (result.code === 401) {
                  this.$router.push('UserLogin')
                  alert("您未登录，请登录")
                } else {
                  //数据赋值
                  //进行数据赋值
                  this.tableData[this.tableDataScope.$index]=this.formTableData
                  this.tableDataTemp=_.cloneDeep(this.formTableData)
                  this.dialogTableHeader=false;
                  alert("修改成功")
                }
              })
            }
            else if (doe===3){
              //是删除操作，用修改一个字段的形式实现，但是这个是根据id修改一个int类型的。
              this.$request.post('editOperateGuideBookFieldInt',{
                id:this.tableDataScope.row.id,
                fieldName:'deleteSign',
                fieldVal:0,
              }).then(result=>{
                if (result.code === 401) {
                  this.$router.push('UserLogin')
                  alert("您未登录，请登录")
                } else {
                  //组合数据
                  //删除大表中的内容
                  this.tableData.splice(this.tableDataScope.$index,1);
                  this.tableDataTemp={
                    //id主键
                    id:'',
                    //车间名称
                    workshop:'',
                    //线体名称
                    lineName:'',
                    //工序名称
                    op:'',
                    //文件名称
                    fileName:'',
                    // 版本号
                    editionNum:'',
                    //编制日期
                    writeDate:'',
                    //执行日期
                    executeDate:'',
                    //文件编号
                    fileNum:'',
                    //编制
                    writeUse:'',
                    //审核
                    examineUse:'',
                    //批准
                    ratifyUse:'',
                    //会签
                    countersignUse:'',
                    //作业指导书
                    workBook:'',
                    //产品图号
                    productId:'',
                    // 视频附件
                    BookVideo:'',
                    // 修改记录
                    editRecord:'',
                    //指导书类型
                    bookType:'',
                    //删除标记位
                    deleteSign:'',
                    //创建时间
                    establishTime:'',
                    //修改时间
                    UpdateTime:'',
                  }
                  this.workBook=[]
                  this.tableDataScope=null
                  this.dialogTableHeader=false
                }
              })
            }

        } else {
          console.log('error submit!!');
          return false;
        }
      });
    },

    //对作业指导书操作，添加、编辑、删除，控制计划的关联设置等，所有的作业指导书编辑部分的函数
    editBook(doe,scope){
      this.loading=false
      //把用户现在的类型传递出去，1：编辑作业指导书；2.增加一个作业指导书的步骤；3.删除作业指导书；4.增加这个条目下的图片；5.增加这条目下的视频；
      this.editBookUse=doe
      //把用户选择的作业指导书的scope格式传递出去。
      this.editBookScope=scope

      if (this.treeNode===null){
        alert("请先选择工序")
        return
      }
      //是编辑操作
        if (this.editBookUse===1){
          this.inputText1=''
          this.inputTextEnglish1=''
          this.inputTextRussian1=''
          this.inputText4=''
          this.inputTextEnglish4=''
          this.inputTextRussian4=''
          this.inputText5=''
          this.inputTextEnglish5=''
          this.inputTextRussian5=''
          this.inputText6=''
          this.inputTextEnglish6=''
          this.inputTextRussian6=''
          //进行初始赋值
          this.titleUse='您正在编辑本条步骤'
          //组合作业指导书步骤
          if (this.editBookScope.row.work!=='' && this.editBookScope.row.work!==null && this.editBookScope.row.work!==undefined){
            if (this.editBookScope.row.work.split('|*|').length===3){
              this.inputText1=_.cloneDeep(this.editBookScope.row.work.split('|*|'))[0]
              this.inputTextEnglish1=_.cloneDeep(this.editBookScope.row.work.split('|*|'))[1]
              this.inputTextRussian1=_.cloneDeep(this.editBookScope.row.work.split('|*|'))[2]
            }
            else {
              this.inputText1=_.cloneDeep(this.editBookScope.row.work)
              this.inputTextEnglish1=''
              this.inputTextRussian1=''
            }
          }
          //组合
          if (this.editBookScope.row.device!=='' && this.editBookScope.row.device!==null && this.editBookScope.row.device!==undefined){
            if (this.editBookScope.row.device.split('|*|').length===3){
              this.inputText4=_.cloneDeep(this.editBookScope.row.device.split('|*|'))[0]
              this.inputTextEnglish4=_.cloneDeep(this.editBookScope.row.device.split('|*|'))[1]
              this.inputTextRussian4=_.cloneDeep(this.editBookScope.row.device.split('|*|'))[2]
            }
            else {
              this.inputText4=_.cloneDeep(this.editBookScope.row.device)
              this.inputTextEnglish4=''
              this.inputTextRussian4=''
            }
          }
          //组合
          if (this.editBookScope.row.accessories!=='' && this.editBookScope.row.accessories!==null && this.editBookScope.row.accessories!==undefined){
            if (this.editBookScope.row.accessories.split('|*|').length===3){
              this.inputText5=_.cloneDeep(this.editBookScope.row.accessories.split('|*|'))[0]
              this.inputTextEnglish5=_.cloneDeep(this.editBookScope.row.accessories.split('|*|'))[1]
              this.inputTextRussian5=_.cloneDeep(this.editBookScope.row.accessories.split('|*|'))[2]
            }
            else {
              this.inputText5=_.cloneDeep(this.editBookScope.row.accessories)
              this.inputTextEnglish5=''
              this.inputTextRussian5=''
            }
          }
          //组合
          if (this.editBookScope.row.toll!=='' && this.editBookScope.row.toll!==null && this.editBookScope.row.toll!==undefined){
            if (this.editBookScope.row.toll.split('|*|').length===3){
              this.inputText6=_.cloneDeep(this.editBookScope.row.toll.split('|*|'))[0]
              this.inputTextEnglish6=_.cloneDeep(this.editBookScope.row.toll.split('|*|'))[1]
              this.inputTextRussian6=_.cloneDeep(this.editBookScope.row.toll.split('|*|'))[2]
            }
            else {
              this.inputText6=_.cloneDeep(this.editBookScope.row.toll)
              this.inputTextEnglish6=''
              this.inputTextRussian6=''
            }
          }
          //组合
          if (this.editBookScope.row.toll!=='' && this.editBookScope.row.toll!==null && this.editBookScope.row.toll!==undefined){
            if (this.editBookScope.row.toll.split('|*|').length===3){
              this.inputText6=_.cloneDeep(this.editBookScope.row.toll.split('|*|'))[0]
              this.inputTextEnglish6=_.cloneDeep(this.editBookScope.row.toll.split('|*|'))[1]
              this.inputTextRussian6=_.cloneDeep(this.editBookScope.row.toll.split('|*|'))[2]
            }
            else {
              this.inputText6=_.cloneDeep(this.editBookScope.row.work)
              this.inputTextEnglish6=''
              this.inputTextRussian6=''
            }
          }
          this.inputNum=_.cloneDeep(this.editBookScope.row.spendTime)
          this.inputText7=_.cloneDeep(this.editBookScope.row.startSignal)
          this.inputText8=_.cloneDeep(this.editBookScope.row.endSignal)

          //将注意点和品质检查拆分
          let tempProblem=scope.row.problem.split('|*|')
          let tempInspect=scope.row.inspect.split('|*|')
          this.dialogVisibleText=true

          //初始化富文本编辑器，把拆分后的中英俄赋值给中英俄富文本输入框
          this.$nextTick(() => {
            this.initEditor('pointsChineseEditor', 'pointsChineseEditor', tempProblem[0]);
            this.initEditor('pointsEnglishEditor', 'pointsEnglishEditor', tempProblem[1]);
            this.initEditor('pointsRussianEditor', 'pointsRussianEditor', tempProblem[2]);
            this.initEditor('qualityCheckChineseEditor', 'qualityCheckChineseEditor',tempInspect[0]);
            this.initEditor('qualityCheckEnglishEditor', 'qualityCheckEnglishEditor',tempInspect[1]);
            this.initEditor('qualityCheckRussianEditor', 'qualityCheckRussianEditor',tempInspect[2]);
          })
        }
        //是一向下插入操作
        else if (this.editBookUse===2){
          //初始化数据
          this.titleUse='您正在向下插入一个新的步骤'
          this.inputText1=''
          this.inputTextEnglish1=''
          this.inputTextRussian1=''
          this.inputText4=''
          this.inputText5=''
          this.inputText6=''
          this.inputNum=0
          this.inputText7=0
          this.inputText8=0

          this.dialogVisibleText=true

          //初始化富文本编辑器
          this.$nextTick(() => {
            this.initEditor('pointsChineseEditor', 'pointsChineseEditor', '');
            this.initEditor('pointsEnglishEditor', 'pointsEnglishEditor', '');
            this.initEditor('pointsRussianEditor', 'pointsRussianEditor', '');
            this.initEditor('qualityCheckChineseEditor', 'qualityCheckChineseEditor','');
            this.initEditor('qualityCheckEnglishEditor', 'qualityCheckEnglishEditor','');
            this.initEditor('qualityCheckRussianEditor', 'qualityCheckRussianEditor','');
          })
        }
        //是一向上插入操作
        else if (this.editBookUse===7){
          //初始化数据
          this.titleUse='您正在向上插入一个新的步骤'
          //组合作业指导书步骤
          this.inputText1=''
          this.inputTextEnglish1=''
          this.inputTextRussian1=''
          this.inputText4=''
          this.inputText5=''
          this.inputText6=''
          this.inputNum=0
          this.inputText7=0
          this.inputText8=0

          this.dialogVisibleText=true

          //初始化富文本编辑器
          this.$nextTick(() => {
            this.initEditor('pointsChineseEditor', 'pointsChineseEditor', '');
            this.initEditor('pointsEnglishEditor', 'pointsEnglishEditor', '');
            this.initEditor('pointsRussianEditor', 'pointsRussianEditor', '');
            this.initEditor('qualityCheckChineseEditor', 'qualityCheckChineseEditor','');
            this.initEditor('qualityCheckEnglishEditor', 'qualityCheckEnglishEditor','');
            this.initEditor('qualityCheckRussianEditor', 'qualityCheckRussianEditor','');
          })
        }
        //是删除操作
        else if (this.editBookUse===3){
          //进行初始赋值
          this.titleUse='您正在删除本条步骤'
          this.inputText1=_.cloneDeep(this.editBookScope.row.work)
          this.inputText4=_.cloneDeep(this.editBookScope.row.device)
          this.inputText5=_.cloneDeep(this.editBookScope.row.accessories)
          this.inputText6=_.cloneDeep(this.editBookScope.row.toll)
          this.inputNum=_.cloneDeep(this.editBookScope.row.spendTime)
          this.inputText7=_.cloneDeep(this.editBookScope.row.startSignal)
          this.inputText8=_.cloneDeep(this.editBookScope.row.endSignal)
          //将注意点和品质检查拆分
          let tempProblem=scope.row.problem.split('|*|')
          let tempInspect=scope.row.inspect.split('|*|')
          this.dialogVisibleText=true
          //初始化富文本编辑器，把拆分后的中英俄赋值给中英俄富文本输入框
          this.$nextTick(() => {
            this.initEditor('pointsChineseEditor', 'pointsChineseEditor', tempProblem[0]);
            this.initEditor('pointsEnglishEditor', 'pointsEnglishEditor', tempProblem[1]);
            this.initEditor('pointsRussianEditor', 'pointsRussianEditor', tempProblem[2]);
            this.initEditor('qualityCheckChineseEditor', 'qualityCheckChineseEditor',tempInspect[0]);
            this.initEditor('qualityCheckEnglishEditor', 'qualityCheckEnglishEditor',tempInspect[1]);
            this.initEditor('qualityCheckRussianEditor', 'qualityCheckRussianEditor',tempInspect[2]);
          })
        }
        else if (this.editBookUse===4){
          //是编辑照片的操作，包括添加、删除。
          //组合图片编辑列表的数据
          //组合照片的数据
          if (this.editBookScope.row.pictureList.includes('undefined')){
            //没有图片信息
            this.PictureList = []
          }
          else {
            this.PictureList = []
            const temp1 = this.editBookScope.row.pictureList.split('|*|')
            for (let i = 0; i < temp1.length - 1; i++) {
              let temp2 = {
                name: temp1[i],
                percentage: 0,
                raw: File,
                size: 0,
                status: null,
                uid: null,
                url: filepath + temp1[i]
              }
              this.PictureList.push(temp2)
            }
          }
          this.titleUse='您正在编辑本行的图片信息'
          this.fileType='image/jpeg, image/png'
          this.dialogPicture=true
        }
        else if (this.editBookUse===5){
          //在装配作业指导书中编辑视频操作，包括添加、删除。
          //组合视频编辑列表的数据
          //组合视频的数据
          if (this.editBookScope.row.videoList.includes('undefined')){
            //没有视频信息
            this.videoList = []
          }
          else {
            this.videoList = []
            const temp1 = this.editBookScope.row.videoList.split('|*|')
            for (let i = 0; i < temp1.length - 1; i++) {
              let temp2 = {
                name: temp1[i],
                percentage: 0,
                raw: File,
                size: 0,
                status: null,
                uid: null,
                url: filepath + temp1[i]
              }
              this.videoList.push(temp2)
            }
          }
          this.fileType='video/mp4, video/x-matroska, video/quicktime, video/webm'
          this.titleUse='您正在编辑本行的视频信息'
          this.dialogVideo=true
        }
        else if (this.editBookUse===6){
          //点击的是编辑控制计划内容，关联控制计划的编辑页。
          this.titleUse='编辑控制计划管理项目'
          this.controlPlanSelection=[]
          this.tableDataControl=[]
          this.dialogVisibleControl=true
        }
        else if (this.editBookUse===100){
          //需要查看作业指导的图片，没有其他的编辑内容,是组合走马灯照片或者视频的
          //组合走马灯的照片
          if (this.editBookScope.row.pictureList.includes('undefined')){
            this.itemView=[]
          }
          else {
            let pictureTemp=this.editBookScope.row.pictureList.split('|*|')
            this.itemView=[]
            for (let i = 0; i < pictureTemp.length-1; i++) {
              let temp=filepath+pictureTemp[i]
              this.itemView.push(temp)
            }
          }
          //组合走马灯的视频
          if (this.editBookScope.row.videoList.includes('undefined')){
            this.itemViewVideo=[]
          }
          else {
            let pictureTemp=this.editBookScope.row.videoList.split('|*|')
            this.itemViewVideo=[]
            for (let i = 0; i < pictureTemp.length-1; i++) {
              let temp=filepath+pictureTemp[i]
              this.itemViewVideo.push(temp)
            }
          }
        }
    },

    //生成唯一标识码的函数（利用时间戳和随机数）
    generateUniqueId() {
      return Date.now().toString() + Math.random().toString(36).slice(2, 11);
    },
    //保存作业指导书部分的数据的函数
    saveDataTextTwo(){
      //是编辑操作
        if (this.editBookUse===1){
          if (this.inputNum===0){
            alert("本工步无时间，请核对")
            return
          }
          //是装配作业指导书下的修改某一个条目的操作|*||*|
          if (this.inputText1==='' || this.inputText1===null || this.inputText1===undefined){
            this.inputText1='作业指导书步骤'
          }
          if (this.inputTextEnglish1==='' || this.inputTextEnglish1===null || this.inputTextEnglish1===undefined){
            this.inputTextEnglish1='Steps of homework instruction manual'
          }
          if (this.inputTextRussian1==='' || this.inputTextRussian1===null || this.inputTextRussian1===undefined){
            this.inputTextRussian1='Этапы руководства по оперативной деятельности'
          }
          //是装配作业指导书下的修改某一个设备
          if (this.inputText4==='' || this.inputText4===null || this.inputText4===undefined){
            this.inputText4='无'
          }
          if (this.inputTextEnglish4==='' || this.inputTextEnglish4===null || this.inputTextEnglish4===undefined){
            this.inputTextEnglish4='not have'
          }
          if (this.inputTextRussian4==='' || this.inputTextRussian4===null || this.inputTextRussian4===undefined){
            this.inputTextRussian4='Нет'
          }
          //是装配作业指导书下的修改某一个辅料
          if (this.inputText5==='' || this.inputText5===null || this.inputText5===undefined){
            this.inputText5='无'
          }
          if (this.inputTextEnglish5==='' || this.inputTextEnglish5===null || this.inputTextEnglish5===undefined){
            this.inputTextEnglish5='not have'
          }
          if (this.inputTextRussian5==='' || this.inputTextRussian5===null || this.inputTextRussian5===undefined){
            this.inputTextRussian5='Нет'
          }
          //是装配作业指导书下的修改某一个工具
          if (this.inputText6==='' || this.inputText6===null || this.inputText6===undefined){
            this.inputText6='无'
          }
          if (this.inputTextEnglish6==='' || this.inputTextEnglish6===null || this.inputTextEnglish6===undefined){
            this.inputTextEnglish6='not have'
          }
          if (this.inputTextRussian6==='' || this.inputTextRussian6===null || this.inputTextRussian6===undefined){
            this.inputTextRussian6='Нет'
          }
          // 处理 inputText7
          if (this.inputText7 === '' || this.inputText7 === 0 || this.inputText7 === '0') {
            this.inputText7 = 'no';
          } else if (/^[1-9]$/.test(this.inputText7)) { // 如果是一位数数字(1-9)
            this.inputText7 = '0' + this.inputText7; // 前面补零
          }
          // 处理 inputText8
          if (this.inputText8 === '' || this.inputText8 === 0 || this.inputText8 === '0') {
            this.inputText8 = 'no';
          } else if (/^[1-9]$/.test(this.inputText8)) { // 如果是一位数数字(1-9)
            this.inputText8 = '0' + this.inputText8; // 前面补零
          }

          //赋值富文本为空的情况
          if (this.pointsChineseEditor.txt.html()==='' ||this.pointsChineseEditor.txt.html()===undefined || this.pointsChineseEditor.txt.html===null){
            this.pointsChineseEditor.txt.html('无注意点')
          }
          if (this.pointsEnglishEditor.txt.html()==='' ||this.pointsEnglishEditor.txt.html()===undefined || this.pointsEnglishEditor.txt.html===null){
            this.pointsEnglishEditor.txt.html('No Attention Points')
          }
          if (this.pointsRussianEditor.txt.html()==='' ||this.pointsRussianEditor.txt.html()===undefined || this.pointsRussianEditor.txt.html===null){
            this.pointsRussianEditor.txt.html('Нет точек внимания')
          }
          if (this.qualityCheckChineseEditor.txt.html()==='' ||this.qualityCheckChineseEditor.txt.html()===undefined || this.qualityCheckChineseEditor.txt.html===null){
            this.qualityCheckChineseEditor.txt.html('无品质检查')
          }
          if (this.qualityCheckEnglishEditor.txt.html()==='' ||this.qualityCheckEnglishEditor.txt.html()===undefined || this.qualityCheckEnglishEditor.txt.html===null){
            this.qualityCheckEnglishEditor.txt.html('No quality check')
          }
          if (this.qualityCheckChineseEditor.txt.html()==='' ||this.qualityCheckRussianEditor.txt.html()===undefined || this.qualityCheckRussianEditor.txt.html===null){
            this.qualityCheckRussianEditor.txt.html('Нет проверки качества')
          }
          //组合数据
          //向总数据中进行组合
          let temp=_.cloneDeep(this.workBook)
          temp[this.editBookScope.$index].work=this.inputText1+'|*|'+this.inputTextEnglish1+'|*|'+this.inputTextRussian1
          temp[this.editBookScope.$index].problem=this.pointsChineseEditor.txt.html()+'|*|'+this.pointsEnglishEditor.txt.html()+'|*|'+this.pointsRussianEditor.txt.html()
          temp[this.editBookScope.$index].inspect=this.qualityCheckChineseEditor.txt.html()+'|*|'+this.qualityCheckEnglishEditor.txt.html()+'|*|'+this.qualityCheckRussianEditor.txt.html()
          temp[this.editBookScope.$index].device=this.inputText4+'|*|'+this.inputTextEnglish4+'|*|'+this.inputTextRussian4
          temp[this.editBookScope.$index].accessories=this.inputText5+'|*|'+this.inputTextEnglish5+'|*|'+this.inputTextRussian5
          temp[this.editBookScope.$index].toll=this.inputText6+'|*|'+this.inputTextEnglish6+'|*|'+this.inputTextRussian6
          temp[this.editBookScope.$index].spendTime=this.inputNum
          temp[this.editBookScope.$index].startSignal=this.inputText7
          temp[this.editBookScope.$index].endSignal=this.inputText8

          //组合成为文本数据，用的方法是，先把每一条的数据组合起来。
          let strTemp=''//组合的临时变量,用在向后端保存数据的变量
          for (let i = 0; i < temp.length; i++) {
            //组合自己每一条的变量
            let itemStr=temp[i].work+'|%|'+temp[i].problem+'|%|'+temp[i].inspect+'|%|'+temp[i].spendTime
                +'|%|'+temp[i].controlPlan+'|%|'+temp[i].toll+'|%|'+temp[i].accessories+'|%|'+temp[i].device
                +'|%|'+temp[i].pictureList+'|%|'+temp[i].videoList+'|%|'+temp[i].startSignal+'|%|'+temp[i].endSignal+'|%|'
            strTemp=strTemp+itemStr+'|-|'
          }
          //校验字符数量
          if(new TextEncoder().encode(strTemp).length >= 5500000){
            this.$message.warning("所有步骤的字数总和超出限制，请精简语句")
            return;
          }

          //向后端发动数据，进行保存
          this.$request.post('editOperateGuideBookField',{
            id:this.tableDataScope.row.id,
            fieldName:'workBook',
            fieldVal:strTemp,
            fieldValOld:this.tableDataScope.row.workBook,
            editUseName:this.useName
          })
              .then(result=>{
                if (result.code === 401) {
                  this.$router.push('UserLogin')
                  alert("您未登录，请登录")
                }
                else {
                  this.dialogVisibleText=false
                  this.$message.success('修改成功')
                  //对新数据进行重新赋值
                  this.tableData[this.tableDataScope.$index].workBook=result.data
                  //把数据赋值给临时的数据
                  this.tableDataTemp=_.cloneDeep(this.tableData[this.tableDataScope.$index])
                  //重新组合数据
                  //组合作业指导书的内容
                  //把数据进行分割,分割出步骤一条一条的。
                  const temp=this.tableDataTemp.workBook.split('|-|')
                  // 对每一条的数据进行处理
                  this.workBook=[]
                  for (let i = 0; i < temp.length-1; i++) {
                    //对数据进行分割
                    const time=temp[i].split('|%|')
                    // 组合数据
                    const timeTemp={
                      id:0,
                      work:time[0],//工作项目
                      problem:time[1],//关注点
                      inspect:time[2],//品质检查
                      spendTime:time[3],//需要的时间
                      controlPlan:time[4],//控制计划的关联项
                      toll:time[5],//工具
                      device:time[7],//设备
                      accessories:time[6],//辅料,
                      pictureList:time[8],//图片列表数据
                      videoList:time[9],//视频列表数据
                      startSignal:time[10],//开始的信号
                      endSignal:time[11],//结束的信号
                    }

                    this.workBook.push(timeTemp)
                  }
                  this.LanguageChange()
                }
              })
        }
        //是向下插入操作
        else if (this.editBookUse===2){
          if (this.inputNum===0){
            alert("本工步无时间，请核对")
            return
          }
          //是装配作业指导书下的修改某一个条目的操作
          if (this.inputText1==='' || this.inputText1===null || this.inputText1===undefined){
            this.inputText1='作业指导书步骤'
          }
          if (this.inputTextEnglish1==='' || this.inputTextEnglish1===null || this.inputTextEnglish1===undefined){
            this.inputTextEnglish1='Steps of homework instruction manual'
          }
          if (this.inputTextRussian1==='' || this.inputTextRussian1===null || this.inputTextRussian1===undefined){
            this.inputTextRussian1='Этапы руководства по оперативной деятельности'
          }

          //是装配作业指导书下的修改某一个设备
          if (this.inputText4==='' || this.inputText4===null || this.inputText4===undefined){
            this.inputText4='无'
          }
          if (this.inputTextEnglish4==='' || this.inputTextEnglish4===null || this.inputTextEnglish4===undefined){
            this.inputTextEnglish4='not have'
          }
          if (this.inputTextRussian4==='' || this.inputTextRussian4===null || this.inputTextRussian4===undefined){
            this.inputTextRussian4='Нет'
          }
          //是装配作业指导书下的修改某一个辅料
          if (this.inputText5==='' || this.inputText5===null || this.inputText5===undefined){
            this.inputText5='无'
          }
          if (this.inputTextEnglish5==='' || this.inputTextEnglish5===null || this.inputTextEnglish5===undefined){
            this.inputTextEnglish5='not have'
          }
          if (this.inputTextRussian5==='' || this.inputTextRussian5===null || this.inputTextRussian5===undefined){
            this.inputTextRussian5='Нет'
          }
          //是装配作业指导书下的修改某一个工具
          if (this.inputText6==='' || this.inputText6===null || this.inputText6===undefined){
            this.inputText6='无'
          }
          if (this.inputTextEnglish6==='' || this.inputTextEnglish6===null || this.inputTextEnglish6===undefined){
            this.inputTextEnglish6='not have'
          }
          if (this.inputTextRussian6==='' || this.inputTextRussian6===null || this.inputTextRussian6===undefined){
            this.inputTextRussian6='Нет'
          }

          if (this.inputText7==='' || this.inputText7===0 || this.inputText7==='0'){
            this.inputText7='no'
          }
          if (this.inputText8==='' || this.inputText8===0 || this.inputText8==='0'){
            this.inputText8='no'
          }
          // 赋值富文本为空的情况
          if (this.pointsChineseEditor.txt.html()==='' ||this.pointsChineseEditor.txt.html()===undefined || this.pointsChineseEditor.txt.html===null){
            this.pointsChineseEditor.txt.html('无注意点')
          }
          if (this.pointsEnglishEditor.txt.html()==='' ||this.pointsEnglishEditor.txt.html()===undefined || this.pointsEnglishEditor.txt.html===null){
            this.pointsEnglishEditor.txt.html('No Attention Points')
          }
          if (this.pointsRussianEditor.txt.html()==='' ||this.pointsRussianEditor.txt.html()===undefined || this.pointsRussianEditor.txt.html===null){
            this.pointsRussianEditor.txt.html('Нет точек внимания')
          }
          if (this.qualityCheckChineseEditor.txt.html()==='' ||this.qualityCheckChineseEditor.txt.html()===undefined || this.qualityCheckChineseEditor.txt.html===null){
            this.qualityCheckChineseEditor.txt.html('无品质检查')
          }
          if (this.qualityCheckEnglishEditor.txt.html()==='' ||this.qualityCheckEnglishEditor.txt.html()===undefined || this.qualityCheckEnglishEditor.txt.html===null){
            this.qualityCheckEnglishEditor.txt.html('No quality check')
          }
          if (this.qualityCheckChineseEditor.txt.html()==='' ||this.qualityCheckRussianEditor.txt.html()===undefined || this.qualityCheckRussianEditor.txt.html===null){
            this.qualityCheckRussianEditor.txt.html('Нет проверки качества')
          }
          //组合数据
          //向总数据中进行组合
          const workBookTemp={
            id:-1,
            work:this.inputText1+'|*|'+this.inputTextEnglish1+'|*|'+this.inputTextRussian1,//工作项目
            problem:this.pointsChineseEditor.txt.html()+'|*|'+this.pointsEnglishEditor.txt.html()+'|*|'+this.pointsRussianEditor.txt.html(),//关注点
            inspect:this.qualityCheckChineseEditor.txt.html()+'|*|'+this.qualityCheckEnglishEditor.txt.html()+'|*|'+this.qualityCheckRussianEditor.txt.html(),//品质检查
            spendTime: this.inputNum,//用时，单位S
            controlPlan:-1,//控制计划的关联项
            toll:this.inputText6+'|*|'+this.inputTextEnglish6+'|*|'+this.inputTextRussian6,//工具
            device:this.inputText4+'|*|'+this.inputTextEnglish4+'|*|'+this.inputTextRussian4,//设备
            accessories:this.inputText5+'|*|'+this.inputTextEnglish5+'|*|'+this.inputTextRussian5,//辅料,
            pictureList:'undefined|*|',//图片列表
            videoList:'undefined|*|',
            startSignal:this.inputText7,
            endSignal:this.inputText8
          }
          //拷贝数据
          let temp=_.cloneDeep(this.workBook)
          //插入数据
          temp.splice(this.editBookScope.$index+1,0,workBookTemp)
          //组合成为文本数据，用的方法是，先把每一条的数据组合起来。
          let strTemp=''//组合的临时变量,用在向后端保存数据的变量
          for (let i = 0; i < temp.length; i++) {
            //组合自己每一条的变量
            let itemStr=temp[i].work+'|%|'+temp[i].problem+'|%|'+temp[i].inspect+'|%|'+temp[i].spendTime
                +'|%|'+temp[i].controlPlan+'|%|'+temp[i].toll+'|%|'+temp[i].accessories+'|%|'+temp[i].device
                +'|%|'+temp[i].pictureList+'|%|'+temp[i].videoList+'|%|'+temp[i].startSignal+'|%|'+temp[i].endSignal+'|%|'
            strTemp=strTemp+itemStr+'|-|'
          }

          //校验字符数量
          if(new TextEncoder().encode(strTemp).length >= 65000){
            this.$message.warning("所有步骤的字数总和超出限制，请精简语句")
            return;
          }
          //向后端发动数据，进行保存
          this.$request.post('editOperateGuideBookField',{
            id:this.tableDataScope.row.id,
            fieldName:'workBook',
            fieldVal:strTemp,
            fieldValOld:this.tableDataScope.row.workBook,
            editUseName:this.useName
          })
              .then(result=>{
                if (result.code === 401) {
                  this.$router.push('UserLogin')
                  alert("您未登录，请登录")
                } else {
                  this.dialogVisibleText=false
                  this.$message.success('修改成功')
                  //对新数据进行重新赋值
                  this.tableData[this.tableDataScope.$index].workBook=result.data
                  //把数据赋值给临时的数据
                  this.tableDataTemp=_.cloneDeep(this.tableData[this.tableDataScope.$index])
                  //重新组合数据
                  //组合作业指导书的内容
                  //把数据进行分割,分割出步骤一条一条的。
                  const temp=this.tableDataTemp.workBook.split('|-|')
                  // 对每一条的数据进行处理
                  this.workBook=[]
                  for (let i = 0; i < temp.length-1; i++) {
                    //对数据进行分割
                    const time=temp[i].split('|%|')
                    // 组合数据
                    const timeTemp={
                      id:0,
                      work:time[0],//工作项目
                      problem:time[1],//关注点
                      inspect:time[2],//品质检查
                      spendTime:time[3],//需要的时间
                      controlPlan:time[4],//控制计划的关联项
                      toll:time[5],//工具
                      device:time[7],//设备
                      accessories:time[6],//辅料,
                      pictureList:time[8],//图片列表数据
                      videoList:time[9],//视频列表数据
                      startSignal:time[10],//开始的信号
                      endSignal:time[11],//结束的信号
                    }

                    this.workBook.push(timeTemp)
                  }
                  this.LanguageChange()
                }
              })
        }
        //是向上插入操作
        else if (this.editBookUse===7){
          if (this.inputNum===0){
            alert("本工步无时间，请核对")
            return
          }
          //是装配作业指导书下的修改某一个条目的操作
          if (this.inputText1==='' || this.inputText1===null || this.inputText1===undefined){
            this.inputText1='作业指导书步骤'
          }
          if (this.inputTextEnglish1==='' || this.inputTextEnglish1===null || this.inputTextEnglish1===undefined){
            this.inputTextEnglish1='Steps of homework instruction manual'
          }
          if (this.inputTextRussian1==='' || this.inputTextRussian1===null || this.inputTextRussian1===undefined){
            this.inputTextRussian1='Этапы руководства по оперативной деятельности'
          }

          //是装配作业指导书下的修改某一个设备
          if (this.inputText4==='' || this.inputText4===null || this.inputText4===undefined){
            this.inputText4='无'
          }
          if (this.inputTextEnglish4==='' || this.inputTextEnglish4===null || this.inputTextEnglish4===undefined){
            this.inputTextEnglish4='not have'
          }
          if (this.inputTextRussian4==='' || this.inputTextRussian4===null || this.inputTextRussian4===undefined){
            this.inputTextRussian4='Нет'
          }
          //是装配作业指导书下的修改某一个辅料
          if (this.inputText5==='' || this.inputText5===null || this.inputText5===undefined){
            this.inputText5='无'
          }
          if (this.inputTextEnglish5==='' || this.inputTextEnglish5===null || this.inputTextEnglish5===undefined){
            this.inputTextEnglish5='not have'
          }
          if (this.inputTextRussian5==='' || this.inputTextRussian5===null || this.inputTextRussian5===undefined){
            this.inputTextRussian5='Нет'
          }
          //是装配作业指导书下的修改某一个工具
          if (this.inputText6==='' || this.inputText6===null || this.inputText6===undefined){
            this.inputText6='无'
          }
          if (this.inputTextEnglish6==='' || this.inputTextEnglish6===null || this.inputTextEnglish6===undefined){
            this.inputTextEnglish6='not have'
          }
          if (this.inputTextRussian6==='' || this.inputTextRussian6===null || this.inputTextRussian6===undefined){
            this.inputTextRussian6='Нет'
          }

          if (this.inputText7==='' || this.inputText7===0 || this.inputText7==='0'){
            this.inputText7='no'
          }
          if (this.inputText8==='' || this.inputText8===0 || this.inputText8==='0'){
            this.inputText8='no'
          }
          // 赋值富文本为空的情况
          if (this.pointsChineseEditor.txt.html()==='' ||this.pointsChineseEditor.txt.html()===undefined || this.pointsChineseEditor.txt.html===null){
            this.pointsChineseEditor.txt.html('无注意点')
          }
          if (this.pointsEnglishEditor.txt.html()==='' ||this.pointsEnglishEditor.txt.html()===undefined || this.pointsEnglishEditor.txt.html===null){
            this.pointsEnglishEditor.txt.html('No Attention Points')
          }
          if (this.pointsRussianEditor.txt.html()==='' ||this.pointsRussianEditor.txt.html()===undefined || this.pointsRussianEditor.txt.html===null){
            this.pointsRussianEditor.txt.html('Нет точек внимания')
          }
          if (this.qualityCheckChineseEditor.txt.html()==='' ||this.qualityCheckChineseEditor.txt.html()===undefined || this.qualityCheckChineseEditor.txt.html===null){
            this.qualityCheckChineseEditor.txt.html('无品质检查')
          }
          if (this.qualityCheckEnglishEditor.txt.html()==='' ||this.qualityCheckEnglishEditor.txt.html()===undefined || this.qualityCheckEnglishEditor.txt.html===null){
            this.qualityCheckEnglishEditor.txt.html('No quality check')
          }
          if (this.qualityCheckChineseEditor.txt.html()==='' ||this.qualityCheckRussianEditor.txt.html()===undefined || this.qualityCheckRussianEditor.txt.html===null){
            this.qualityCheckRussianEditor.txt.html('Нет проверки качества')
          }
          //组合数据
          //向总数据中进行组合
          const workBookTemp={
            id:-1,
            work:this.inputText1+'|*|'+this.inputTextEnglish1+'|*|'+this.inputTextRussian1,//工作项目
            problem:this.pointsChineseEditor.txt.html()+'|*|'+this.pointsEnglishEditor.txt.html()+'|*|'+this.pointsRussianEditor.txt.html(),//关注点
            inspect:this.qualityCheckChineseEditor.txt.html()+'|*|'+this.qualityCheckEnglishEditor.txt.html()+'|*|'+this.qualityCheckRussianEditor.txt.html(),//品质检查
            spendTime: this.inputNum,//用时，单位S
            controlPlan:-1,//控制计划的关联项
            toll:this.inputText6+'|*|'+this.inputTextEnglish6+'|*|'+this.inputTextRussian6,//工具
            device:this.inputText4+'|*|'+this.inputTextEnglish4+'|*|'+this.inputTextRussian4,//设备
            accessories:this.inputText5+'|*|'+this.inputTextEnglish5+'|*|'+this.inputTextRussian5,//辅料,
            pictureList:'undefined|*|',//图片列表
            videoList:'undefined|*|',
            startSignal:this.inputText7,
            endSignal:this.inputText8
          }
          //拷贝数据
          let temp=_.cloneDeep(this.workBook)
          //插入数据
          temp.splice(this.editBookScope.$index,0,workBookTemp)
          //组合成为文本数据，用的方法是，先把每一条的数据组合起来。
          let strTemp=''//组合的临时变量,用在向后端保存数据的变量
          for (let i = 0; i < temp.length; i++) {
            //组合自己每一条的变量
            let itemStr=temp[i].work+'|%|'+temp[i].problem+'|%|'+temp[i].inspect+'|%|'+temp[i].spendTime
                +'|%|'+temp[i].controlPlan+'|%|'+temp[i].toll+'|%|'+temp[i].accessories+'|%|'+temp[i].device
                +'|%|'+temp[i].pictureList+'|%|'+temp[i].videoList+'|%|'+temp[i].startSignal+'|%|'+temp[i].endSignal+'|%|'
            strTemp=strTemp+itemStr+'|-|'
          }

          //校验字符数量
          if(new TextEncoder().encode(strTemp).length >= 65000){
            this.$message.warning("所有步骤的字数总和超出限制，请精简语句")
            return;
          }
          //向后端发动数据，进行保存
          this.$request.post('editOperateGuideBookField',{
            id:this.tableDataScope.row.id,
            fieldName:'workBook',
            fieldVal:strTemp,
            fieldValOld:this.tableDataScope.row.workBook,
            editUseName:this.useName
          })
              .then(result=>{
                if (result.code === 401) {
                  this.$router.push('UserLogin')
                  alert("您未登录，请登录")
                } else {
                  this.dialogVisibleText=false
                  this.$message.success('修改成功')
                  //对新数据进行重新赋值
                  this.tableData[this.tableDataScope.$index].workBook=result.data
                  //把数据赋值给临时的数据
                  this.tableDataTemp=_.cloneDeep(this.tableData[this.tableDataScope.$index])
                  //重新组合数据
                  //组合作业指导书的内容
                  //把数据进行分割,分割出步骤一条一条的。
                  const temp=this.tableDataTemp.workBook.split('|-|')
                  // 对每一条的数据进行处理
                  this.workBook=[]
                  for (let i = 0; i < temp.length-1; i++) {
                    //对数据进行分割
                    const time=temp[i].split('|%|')
                    // 组合数据
                    const timeTemp={
                      id:0,
                      work:time[0],//工作项目
                      problem:time[1],//关注点
                      inspect:time[2],//品质检查
                      spendTime:time[3],//需要的时间
                      controlPlan:time[4],//控制计划的关联项
                      toll:time[5],//工具
                      device:time[7],//设备
                      accessories:time[6],//辅料,
                      pictureList:time[8],//图片列表数据
                      videoList:time[9],//视频列表数据
                      startSignal:time[10],//开始的信号
                      endSignal:time[11],//结束的信号
                    }

                    this.workBook.push(timeTemp)
                  }
                  this.LanguageChange()
                }
              })
        }
        else if (this.editBookUse===3){
          //组合数据
          //向总数据中进行组合
          //拷贝数据
          let temp=_.cloneDeep(this.workBook)
          //删除数据
          temp.splice(this.editBookScope.$index,1)
          //组合成为文本数据，用的方法是，先把每一条的数据组合起来。
          let strTemp=''//组合的临时变量,用在向后端保存数据的变量
          for (let i = 0; i < temp.length; i++) {
            //组合自己每一条的变量
            let itemStr=temp[i].work+'|%|'+temp[i].problem+'|%|'+temp[i].inspect+'|%|'+temp[i].spendTime
                +'|%|'+temp[i].controlPlan+'|%|'+temp[i].toll+'|%|'+temp[i].accessories+'|%|'+temp[i].device
                +'|%|'+temp[i].pictureList+'|%|'+temp[i].videoList+'|%|'+temp[i].startSignal+'|%|'+temp[i].endSignal+'|%|'
            strTemp=strTemp+itemStr+'|-|'
          }
          //向后端发动数据，进行保存
          this.$request.post('editOperateGuideBookField',{
            id:this.tableDataScope.row.id,
            fieldName:'workBook',
            fieldVal:strTemp,
            fieldValOld:this.tableDataScope.row.workBook,
            editUseName:this.useName
          })
              .then(result=>{
                if (result.code === 401) {
                  this.$router.push('UserLogin')
                  alert("您未登录，请登录")
                } else {
                  this.dialogVisibleText=false
                  alert("删除成功")
                  //对新数据进行重新赋值
                  this.tableData[this.tableDataScope.$index].workBook=result.data
                  //把数据赋值给临时的数据
                  this.tableDataTemp=_.cloneDeep(this.tableData[this.tableDataScope.$index])
                  //重新组合数据
                  //组合作业指导书的内容
                  //把数据进行分割,分割出步骤一条一条的。
                  const temp=this.tableDataTemp.workBook.split('|-|')
                  // 对每一条的数据进行处理
                  this.workBook=[]
                  for (let i = 0; i < temp.length-1; i++) {
                    //对数据进行分割
                    const time=temp[i].split('|%|')
                    // 组合数据
                    const timeTemp={
                      id:0,
                      work:time[0],//工作项目
                      problem:time[1],//关注点
                      inspect:time[2],//品质检查
                      spendTime:time[3],//需要的时间
                      controlPlan:time[4],//控制计划的关联项
                      toll:time[5],//工具
                      device:time[7],//设备
                      accessories:time[6],//辅料,
                      pictureList:time[8],//图片列表数据
                      videoList:time[9],//视频列表数据
                      startSignal:time[10],//开始的信号
                      endSignal:time[11],//结束的信号
                    }
                    this.workBook.push(timeTemp)
                  }
                  this.LanguageChange()
                }
              })
        }
    },

    //保存控制计划的关联关系
    saveDataControl(){
      //用户要保存控制计划关联项。
      // 每一个步骤可能和多个控制计划关联，每一项之间用到了|*|分割符
      // 组合数据
      let controlPlanStr=''
      for (let i = 0; i < this.controlPlanSelection.length; i++) {
        controlPlanStr=controlPlanStr+this.controlPlanSelection[i].id+'|*|'
      }
      // 重新组合作业指导书的内容
      //向总数据中进行组合
      let temp=_.cloneDeep(this.workBook)
      if (controlPlanStr!==''){
        //向作业指导书中数据赋值
        temp[this.editBookScope.$index].controlPlan=controlPlanStr
        //组合成为文本数据，用的方法是，先把每一条的数据组合起来。
        let strTemp=''//组合的临时变量,用在向后端保存数据的变量
        for (let i = 0; i < temp.length; i++) {
          //组合自己每一条的变量
          let itemStr=temp[i].work+'|%|'+temp[i].problem+'|%|'+temp[i].inspect+'|%|'+temp[i].spendTime
              +'|%|'+temp[i].controlPlan+'|%|'+temp[i].toll+'|%|'+temp[i].accessories+'|%|'+temp[i].device
              +'|%|'+temp[i].pictureList+'|%|'+temp[i].videoList+'|%|'
          strTemp=strTemp+itemStr+'|-|'
        }
        //向后端写入数据
        //向后端发动数据，进行保存
        this.$request.post('editOperateGuideBookField',{
          id:this.tableDataScope.row.id,
          fieldName:'workBook',
          fieldVal:strTemp,
          fieldValOld:this.tableDataScope.row.workBook,
          editUseName:this.useName
        })
            .then(result=>{
              if (result.code === 401) {
                this.$router.push('UserLogin')
                alert("您未登录，请登录")
              }
              else {
                this.dialogVisibleText=false
                //对新数据进行重新赋值
                this.tableData[this.tableDataScope.$index].workBook=result.data
                //把数据赋值给临时的数据
                this.tableDataTemp=_.cloneDeep(this.tableData[this.tableDataScope.$index])
                //重新组合数据
                //组合作业指导书的内容
                //把数据进行分割,分割出步骤一条一条的。
                const temp=this.tableDataTemp.workBook.split('|-|')
                // 对每一条的数据进行处理
                this.workBook=[]
                for (let i = 0; i < temp.length-1; i++) {
                  //对数据进行分割
                  const time=temp[i].split('|%|')
                  // 组合数据
                  const timeTemp={
                    id:0,
                    work:time[0],//工作项目
                    problem:time[1],//关注点
                    inspect:time[2],//品质检查
                    spendTime:time[3],//需要的时间
                    controlPlan:time[4],//控制计划的关联项
                    toll:time[5],//工具
                    device:time[7],//设备
                    accessories:time[6],//辅料,
                    pictureList:time[8],//图片列表数据
                    videoList:time[9],//视频列表数据
                    startSignal:time[10],//起始信号
                    endSignal:time[11],//结束信号
                  }
                  this.workBook.push(timeTemp)
                }
              }
            })
        this.dialogVisibleControl=false
        // 显示成功消息
        this.$message({
          message: '关联成功',
          type: 'success',
          duration: 3000
        });
      }
    },
    //通用的删除键弹窗；现在用到了1、删除控制计划的关联；2、删除人员按钮；
    deleteData(doe, scope) {
      this.deleteDataDoe = doe
      if (doe==='deleteControlPlan'){
        this.titleUse='删除该条控制计划关联'
        this.controlPlanScope=scope
        this.controlPlanForm=_.cloneDeep(scope.row)
        this.deleteDialog = true
      }
      else if (doe==='operatorRowDeleteData'){
        this.titleUse='删除该条人员信息'
        this.operatorListScope=scope
        this.operatorListForm=_.cloneDeep(scope.row)
        this.deleteDialog = true
      }
    },
    //通用的删除键弹窗点击OK；1.删除控制计划关联,2:删除操作人员；
    deleteDataOk() {
      if (this.deleteDataDoe === 'deleteControlPlan') {
        // 获取当前行的控制计划ID
        const controlPlanId = this.controlPlanForm.id;

        // 从当前作业步骤的控制计划关联字符串中移除这个ID
        let controlPlanStr = this.editBookScope.row.controlPlan;
        controlPlanStr = controlPlanStr.replace(controlPlanId + '|*|', '');

        // 如果删除后为空，设置为-1表示没有关联
        if (controlPlanStr === '') {
          controlPlanStr = '-1';
        }

        // 更新当前行的控制计划关联
        let temp = _.cloneDeep(this.workBook);
        let index = this.workBook.findIndex(item=>item.id===this.editBookScope.row.id)
        temp[index].controlPlan = controlPlanStr;

        // 组合成为完整的作业指导书文本数据
        let strTemp = '';
        for (let i = 0; i < temp.length; i++) {
          let itemStr = temp[i].work + '|%|' +
              temp[i].problem + '|%|' +
              temp[i].inspect + '|%|' +
              temp[i].spendTime + '|%|' +
              temp[i].controlPlan + '|%|' +
              temp[i].toll + '|%|' +
              temp[i].accessories + '|%|' +
              temp[i].device + '|%|' +
              temp[i].pictureList + '|%|' +
              temp[i].videoList + '|%|' +
              temp[i].startSignal + '|%|' +
              temp[i].endSignal + '|%|';
          strTemp = strTemp + itemStr + '|-|';
        }

        // 向后端发送请求保存修改
        this.$request.post('editOperateGuideBookField', {
          id: this.tableDataScope.row.id,
          fieldName: 'workBook',
          fieldVal: strTemp,
          fieldValOld: this.tableDataScope.row.workBook,
          editUseName: this.useName
        }).then(result => {
          if (result.code === 401) {
            this.$router.push('UserLogin');
            alert("您未登录，请登录");
          } else {
            // 更新本地数据
            this.tableData[this.tableDataScope.$index].workBook = result.data;
            this.tableDataScope.row.workBook = result.data;
            this.tableDataTemp.workBook = result.data;

            // 重新解析作业指导书数据
            const temp = result.data.split('|-|');
            this.workBook = [];
            for (let i = 0; i < temp.length - 1; i++) {
              const time = temp[i].split('|%|');
              const timeTemp = {
                id: 0,
                work: time[0],
                problem: time[1],
                inspect: time[2],
                spendTime: time[3],
                controlPlan: time[4],
                toll: time[5],
                device: time[7],
                accessories: time[6],
                pictureList: time[8],
                videoList: time[9],
                startSignal: time[10],
                endSignal: time[11]
              };
              this.workBook.push(timeTemp);
            }

            // 关闭弹窗并提示
            this.deleteDialog = false;
            this.$message.success('删除关联成功');
          }
        }).catch(error => {
          console.error('删除控制计划关联失败:', error);
          this.$message.error('删除失败，请重试');
        });
      }
      else if (this.deleteDataDoe==='operatorRowDeleteData'){
        //组合数据
        let operatorListTemp=_.cloneDeep(this.operatorList)
        //删除一行数据
        operatorListTemp.splice(this.operatorListScope.$index,1)
        let str=''
        for (let i = 0; i < operatorListTemp.length; i++) {
          operatorListTemp[i].id=i+1
          //组合数据
          let temp= Object.values(operatorListTemp[i]).join('|%|')
          if (i===0){
            str=temp
          }
          else {
            str=str+'|-|'+temp
          }
        }
        //向后端发送，需要用传输文件的接口
        const formData = new FormData();
        formData.append('file', '')
        formData.append('fieldName','operator')
        formData.append('fieldVal',str)
        formData.append('fileName','')
        formData.append('id',this.tableDataScope.row.id)
        //状态码，0：代表新增；1:代表删除老的，加入新的；即新的替换老的；2：删除老的；
        formData.append('type',2)
        //老文件的文件名称
        formData.append('oldFileName',this.operatorListForm.operator_path)
        this.$requestFile.post('/editOperatorOperateGuideBook',formData).then(result=>{
          if (result.code === 401) {
            this.$router.push('UserLogin')
            alert("您未登录，请登录")
          }
          else {
            //修改大表数据
            this.tableData[this.tableDataScope.$index].operator=str
            //修改scope数据
            this.tableDataScope.row.operator= str
            //修改operatorList数据
            this.operatorList.splice(this.operatorListScope.$index,1)
            //修改图片列表
            this.itemView=[]
            this.itemView.push(filepath+this.operatorListForm.operator_path)
            this.$message.success('删除成功')
            this.deleteDialog=false
          }
        })
      }
    },
    //主表的默认排序
    formatter(row, column) {
      console.log(column)
      return row.address;
    },
    //单击主表某一个数据表的时候，做出的反应（现在函数用在了主表上）
    tableDataClick(doe,scope){
      this.itemView=[]
      this.itemViewVideo=[]
      if (doe===1){
        this.titleMianId=this.treeNode.parent.label
        this.titleMianOp=this.treeNode.data.label
        //现在是主表上的点击
        //把点击击的单元格范围数据发送出去
        this.tableDataScope=scope
        //把数据赋值给临时的数据
        this.tableDataTemp=_.cloneDeep(scope.row)
        //组合作业指导书的内容
        //把数据进行分割,分割出步骤一条一条的。
        const temp=this.tableDataTemp.workBook.split('|-|')
        // 对每一条的数据进行处理
        //对作业指导书进行组合
        this.workBook=[]
        for (let i = 0; i < temp.length-1; i++) {
          //对数据进行分割
          const time=temp[i].split('|%|')
          // 组合数据
          const timeTemp={
            id:0,
            work:time[0],//工作项目
            problem:time[1],//关注点
            inspect:time[2],//品质检查
            spendTime:time[3],//需要的时间
            controlPlan:time[4],//控制计划的关联项
            toll:time[5],//工具
            device:time[7],//设备
            accessories:time[6],//辅料,
            pictureList:time[8],//图片地址列表
            videoList:time[9],//视频地址列表
            startSignal: time[10],//开始信号源
            endSignal: time[11],//结束信号源
          }
          this.workBook.push(timeTemp)
        }
        this.LanguageChange()



        //对零部件列表进行组合
        //新组合零部件明细
        this.partsListData=[]
        let partsTemp=this.tableData[this.tableDataScope.$index].partsList.split('|-|')
        for (let i = 0; i < partsTemp.length-1; i++) {
          let partsItem=partsTemp[i].split('|%|')
          let temp={
            // 图示代码
            mapId:partsItem[0],
            // 工步号
            stepNum:partsItem[1],
            // 零部件编号
            partId:partsItem[2],
            // 零部件名称
            partName:partsItem[3],
            // 数量
            partNum:partsItem[4],
            // 特殊特性
            special:partsItem[5],
            // 最后编辑时间
            endDate:partsItem[6],
            // 最后编辑人
            endName: partsItem[7],
            // 图片列表
            imageList:partsItem[8],
            // 预留
            reserve1:partsItem[9],
            // 预留
            reserve2:partsItem[10],
            // 预留
            reserve3:partsItem[11],
          }
          this.partsListData.push(temp)
        }

        //对失效案例库列表进行组合
        this.caseUseData=[]
        if (this.tableData[this.tableDataScope.$index].caseUse===''){
          this.caseUseData=[]
        }
        else {
          let caseUseTemp=this.tableData[this.tableDataScope.$index].caseUse.split('|-|')
          if (caseUseTemp.length===0){
            caseUseTemp.push(this.tableData[this.tableDataScope.$index].caseUse)
          }
          for (let i = 0; i < caseUseTemp.length; i++) {
            let caseUseItem=caseUseTemp[i].split('|%|')
            let temp={
              id: i,
              caseUse: caseUseItem[0],
              editName: caseUseItem[1],
              editDate: caseUseItem[2],
              pictureList: caseUseItem[3],
              videoList: caseUseItem[4],
              reserve1: caseUseItem[5],
              reserve2: caseUseItem[6],
              reserve3: caseUseItem[7]
            }
            this.caseUseData.push(temp)
          }
        }
        
        //对操作人员进行分割
        this.operatorList=[]
        if (this.tableData[this.tableDataScope.$index].operator==='' || this.tableData[this.tableDataScope.$index].operator===null || this.tableData[this.tableDataScope.$index].operator===undefined){
          this.operatorList=[]
        }
        else {
          let operatorTemp=this.tableData[this.tableDataScope.$index].operator.split('|-|')
          for (let i = 0; i < operatorTemp.length; i++) {
            //进行第二轮循环
            let itemTemp=operatorTemp[i].split('|%|')
            let item={
              //主键
              id:itemTemp[0],
              //工号
              operator_id:itemTemp[1],
              //姓名
              operator_name:itemTemp[2],
              //开始时间
              star_time:itemTemp[3],
              //技能等级
              skill_level:itemTemp[4],
              //指导人
              mentor:itemTemp[5],
              //员工图片路径
              operator_path:itemTemp[6],
              //预留
              reserved1:itemTemp[7],
              reserved2:itemTemp[8],
              reserved3:itemTemp[9],
              reserved4:itemTemp[10],
              reserved5:itemTemp[11],
            }
            this.operatorList.push(item)
          }
        }
        //关闭抽屉
        this.drawer=false
      }
    },
    //单击主表某一个数据表的时候，做出的反应（现在函数用在了主表上）
    tableDataClickCall(scope){
      this.formTableData.lineName=scope.row.lineName
      this.formTableData.editionNum=scope.row.editionNum
      this.formTableData.fileName=scope.row.fileName
      this.formTableData.workBook=scope.row.workBook
      this.formTableData.bookVideo=scope.row.bookVideo
      this.formTableData.editRecord=scope.row.editRecord
      this.formTableData.controlSign=scope.row.controlSign
      this.formTableData.threeBookSign=scope.row.threeBookSign
      this.formTableData.partsList=scope.row.partsList
      this.formTableData.bookType=scope.row.bookType
      this.formTableData.deleteSign=scope.row.deleteSign
        //关闭抽屉
        this.drawerCall=false
      },
    //上传文件的函数(上传图片，视频，是零部件明细中的）
    saveFileAnnexPart(file, fileList){
      this.loading=false
      console.log(fileList)
          //是对图片的操作
          const formData = new FormData()
          //1.新生成一个文件名称,并且把文件名称的后缀添加上
          let fileName=this.generateUniqueId()+'.'+file.name.split('.')[file.name.split('.').length-1]
          //2.记录一个新的图片名称
          let pictureName=''
          //把文件数据放进去
          file.name=fileName
          //把图片加入到自己的图片列表中，好像没有用
          this.PictureList.push(file)
          formData.append('file', file.raw)
          //把原来的图片字符串放进去，作为修改用
          //把数据整合到作业指导书的内容中
          //先判断原来的数据是否有图片
          if (this.partsListScope.row.imageList.includes('undefined')){
            //原来没有图片，需要现在全新生成
            pictureName=fileName+'|*|'
          }
          else {
            //原来已经有图片了
            pictureName=this.partsListScope.row.imageList+fileName+'|*|'
          }
          //重新组合作业指导书的文本内容。
          //组合数据
          //向总数据中进行组合
          let temp=_.cloneDeep(this.partsListData)
          //把新的图片字符串赋值
          temp[this.partsListScope.$index].imageList=pictureName
          //组合成为文本数据，用的方法是，先把每一条的数据组合起来。
          let strTemp=''//组合的临时变量,用在向后端保存数据的变量
          for (let i = 0; i < temp.length; i++) {
            //组合自己每一条的变量
            let itemStr=temp[i].mapId+'|%|'+temp[i].stepNum+'|%|'+temp[i].partId+'|%|'+temp[i].partName
                +'|%|'+temp[i].partNum+'|%|'+temp[i].special+'|%|'+temp[i].endDate+'|%|'+temp[i].endName
                +'|%|'+temp[i].imageList+'|%|'+temp[i].reserve1+'|%|'+temp[i].reserve2+'|%|'+temp[i].reserve3+'|%|'
            strTemp=strTemp+itemStr+'|-|'
          }
          formData.append('id',this.tableDataScope.row.id)
          formData.append('fieldName','partsList')
          formData.append('fieldVal',strTemp)
          formData.append('fileName',fileName)
          this.loading=true
          // 保存文件，需要返回修改后的图片地址保存数据，并且进行赋值
          this.$requestFile.post('/addPictureOperateGuideBook',formData).
          then(result=>{
            if (result.code === 401) {
              this.$router.push('UserLogin')
              alert("您未登录，请登录")
            }else {
              if (result.data===null){
                alert("程序出现异常，请联系管理员")
              }
              else {
                //修改列表中的数据
                //修改主表中的数据和记录的保存数据
                this.tableData[this.tableDataScope.$index].partsList=result.data
                this.tableDataScope.row.partsList=result.data
                //修改作业指导书列表中的内容
                this.partsListData[this.partsListScope.$index].imageList=pictureName
                //组合走马灯的照片
                let pictureTemp=pictureName.split('|*|')
                this.itemView=[]
                for (let i = 0; i < pictureTemp.length-1; i++) {
                  let temp=filepath+pictureTemp[i]
                  this.itemView.push(temp)
                }
              }
              this.loading=false
            }
          })

    },
    //上传文件的函数(上传图片，视频，是作业指导书中的）
    saveFileAnnex(file, fileList){
      this.loading=false
      console.log(fileList)
      if (this.editBookUse===4){
        //是对图片的操作
        const formData = new FormData()
        //1.新生成一个文件名称,并且把文件名称的后缀添加上
        let fileName=this.generateUniqueId()+'.'+file.name.split('.')[file.name.split('.').length-1]
        //2.记录一个新的图片名称
        let pictureName=''
        //把文件数据放进去
        file.name=fileName
        //把图片加入到自己的图片列表中，好像没有用
        this.PictureList.push(file)
        formData.append('file', file.raw)
        //把原来的图片字符串放进去，作为修改用
        //把数据整合到作业指导书的内容中
        //先判断原来的数据是否有图片
        if (this.editBookScope.row.pictureList.includes('undefined')){
          //原来没有图片，需要现在全新生成
          pictureName=fileName+'|*|'
        }
        else {
          //原来已经有图片了
          pictureName=this.editBookScope.row.pictureList+fileName+'|*|'
        }
        //重新组合作业指导书的文本内容。
        //组合数据
        //向总数据中进行组合
        let temp=_.cloneDeep(this.workBook)
        //把新的图片字符串赋值
        temp[this.editBookScope.$index].pictureList=pictureName
        //组合成为文本数据，用的方法是，先把每一条的数据组合起来。
        let strTemp=''//组合的临时变量,用在向后端保存数据的变量
        for (let i = 0; i < temp.length; i++) {
          //组合自己每一条的变量
          let itemStr=temp[i].work+'|%|'+temp[i].problem+'|%|'+temp[i].inspect+'|%|'+temp[i].spendTime
              +'|%|'+temp[i].controlPlan+'|%|'+temp[i].toll+'|%|'+temp[i].accessories+'|%|'+temp[i].device
              +'|%|'+temp[i].pictureList+'|%|'+temp[i].videoList+'|%|'
          strTemp=strTemp+itemStr+'|-|'
        }
        formData.append('id',this.tableDataScope.row.id)
        formData.append('fieldName','workBook')
        formData.append('fieldVal',strTemp)
        formData.append('fileName',fileName)
        this.loading=true
        // 保存文件，需要返回修改后的图片地址保存数据，并且进行赋值
        this.$requestFile.post('/addPictureOperateGuideBook',formData).
        then(result=>{
          if (result.code === 401) {
            this.$router.push('UserLogin')
            alert("您未登录，请登录")
          }else {
            if (result.data===null){
              alert("程序出现异常，请联系管理员")
            }
            else {
              //修改列表中的数据
              //修改主表中的数据和记录的保存数据
              this.tableData[this.tableDataScope.$index].workBook=result.data
              this.tableDataScope.row.workBook=result.data
              //修改作业指导书列表中的内容
              this.workBook[this.editBookScope.$index].pictureList=pictureName
              //组合走马灯的照片
              let pictureTemp=pictureName.split('|*|')
              this.itemView=[]
              for (let i = 0; i < pictureTemp.length-1; i++) {
                let temp=filepath+pictureTemp[i]
                this.itemView.push(temp)
              }
            }
            this.loading=false
          }
        })
      }
      else if (this.editBookUse===5){
        //是编辑视频
        const formData = new FormData()
        //1.新生成一个文件名称,并且把文件名称的后缀添加上
        let fileName=this.generateUniqueId()+'.'+file.name.split('.')[file.name.split('.').length-1]
        //2.记录一个新的视频名称
        let pictureName=''
        //把文件数据放进去（新的文件名称
        file.name=fileName
        //把图片加入到自己的图片列表中，好像没有用
        this.PictureList.push(file)
        formData.append('file', file.raw)
        //把原来的视频字符串放进去，作为修改用
        //把数据整合到作业指导书的内容中
        //先判断原来的数据是否有视频
        if (this.editBookScope.row.videoList.includes('undefined')){
          //原来没有图片，需要现在全新生成
          pictureName=fileName+'|*|'
        }
        else {
          //原来已经有视频了
          pictureName=this.editBookScope.row.videoList+fileName+'|*|'
        }
        //重新组合作业指导书的文本内容。
        //组合数据
        //向总数据中进行组合
        let temp=_.cloneDeep(this.workBook)
        //把新的视频字符串赋值
        temp[this.editBookScope.$index].videoList=pictureName
        //组合成为文本数据，用的方法是，先把每一条的数据组合起来。
        let strTemp=''//组合的临时变量,用在向后端保存数据的变量
        for (let i = 0; i < temp.length; i++) {
          //组合自己每一条的变量
          let itemStr=temp[i].work+'|%|'+temp[i].problem+'|%|'+temp[i].inspect+'|%|'+temp[i].spendTime
              +'|%|'+temp[i].controlPlan+'|%|'+temp[i].toll+'|%|'+temp[i].accessories+'|%|'+temp[i].device
              +'|%|'+temp[i].pictureList+'|%|'+temp[i].videoList+'|%|'
          strTemp=strTemp+itemStr+'|-|'
        }
        formData.append('id',this.tableDataScope.row.id)
        formData.append('fieldName','workBook')
        formData.append('fieldVal',strTemp)
        formData.append('fileName',fileName)

        //打开忙加载
        this.loading=true
        // 保存文件，需要返回修改后的图片地址保存数据，并且进行赋值
        this.$requestFile.post('/addPictureOperateGuideBook',formData).
        then(result=>{
          if (result.code === 401) {
            this.$router.push('UserLogin')
            alert("您未登录，请登录")
          }else {
            if (result.data===null){
              alert("程序出现异常，请联系管理员")
            }else {
              //修改列表中的数据
              //修改主表中的数据和记录的保存数据
              this.tableData[this.tableDataScope.$index].workBook=result.data
              this.tableDataScope.row.workBook=result.data
              //修改作业指导书列表中的内容
              this.workBook[this.editBookScope.$index].videoList=pictureName
              //组合视频走马灯的视频
              if (this.editBookScope.row.videoList.includes('undefined')){
                this.itemViewVideo=[]
              }
              else {
                let pictureTemp=this.editBookScope.row.videoList.split('|*|')
                this.itemViewVideo=[]
                for (let i = 0; i < pictureTemp.length-1; i++) {
                  let temp=filepath+pictureTemp[i]
                  this.itemViewVideo.push(temp)
                }
              }
              //关闭忙加载
              this.loading=false
            }
          }
        })
      }

    },
    //点击查看照片的函数
    handlePictureCardPreview(file) {
      this.dialogImageUrl = file.url;
      this.dialogPictureAnnex = true;
    },
    //单击走马灯上的照片，图片放大方法
    handleImageClick(item){
      this.dialogImageUrl=item
      this.dialogPictureAnnex=true
    },
    //点击图片下载按钮
    handleDownload(file) {
      //向后端发送请求，下载文件
      this.$request.get('/operateGuideBookDownload?fileName=' + encodeURIComponent(file.name)).then(result=>{
        if (result.code === 401) {
          this.$router.push('UserLogin')
          alert("您未登录，请登录")
        }
        else {
          let base64Data = 'data:application/octet-stream;base64,' + result.data//
          // 创建一个Blob对象
          let blob = this.dataURItoBlob(base64Data);
          // 触发下载
          this.downloadBlob(blob, file.name);
        }
      }).catch(error => {
        // 处理请求错误
        console.error("请求出错", error);
      })
    },
    //照片\视频移除的函数(作业指导书中的）
    handleRemove(file) {
      //判断用户是要删除哪里的图片
        if (this.editBookUse===4){
            //是装配作业指导书中的图片
            //对图片列表中的信息进行整合
            const index = this.PictureList.findIndex(item => item.name === file.name);
            this.PictureList.splice(index,1)
            //重新组合作业指导书的文本内容。
            //组合数据
            //向总数据中进行组合
            let temp=_.cloneDeep(this.workBook)
            //把新的图片字符串赋值
            temp[this.editBookScope.$index].pictureList=this.editBookScope.row.pictureList.replace(file.name+'|*|','')
            //判断一下，是不是删除后为空了，如果是，就设置为undefined
            if (temp[this.editBookScope.$index].pictureList===''){
              temp[this.editBookScope.$index].pictureList='undefined|*|'
            }
            //组合成为作业指导书的文本数据，用的方法是，先把每一条的数据组合起来。
            let strTemp=''//组合的临时变量,用在向后端保存数据的变量
            for (let i = 0; i < temp.length; i++) {
              //组合自己每一条的变量
              let itemStr=temp[i].work+'|%|'+temp[i].problem+'|%|'+temp[i].inspect+'|%|'+temp[i].spendTime
                  +'|%|'+temp[i].controlPlan+'|%|'+temp[i].toll+'|%|'+temp[i].accessories+'|%|'+temp[i].device
                  +'|%|'+temp[i].pictureList+'|%|'+temp[i].videoList+'|%|'
              strTemp=strTemp+itemStr+'|-|'
            }
            this.loading=true
            // 发送请求，执行删除文件，发送的是这一行的id，记录图片地址的字符串，以及需要修改的字段，为了减少后端的写的代码，重新返回新的文件名的序列内容，并且更新。
            this.$request.post('/operateGuideBookPictureRemove',{
              id:this.tableDataScope.row.id,
              fieldName:'workBook',
              filedVal:strTemp,
              pictureName:file.name
            }).
            then(result=>{
              if (result.code === 401) {
                this.$router.push('UserLogin')
                alert("您未登录，请登录")
              }
              else {
                if (result.data==='删除文件时出错'){
                  alert("删除文件出错，请联系管理员")
                }else {
                  //修改列表中的数据
                  //修改主表中的数据和记录的保存数据
                  this.tableData[this.tableDataScope.$index].workBook=result.data
                  this.tableDataScope.row.workBook=result.data
                  //组合走马灯的照片
                  if (temp[this.editBookScope.$index].pictureList.includes('undefined')){
                    this.itemView=[]
                  }
                  else {
                    this.itemView=[]
                    let tempView=temp[this.editBookScope.$index].pictureList.split('|*|')
                    for (let i = 0; i < tempView.length-1; i++) {
                      this.itemView.push(filepath+tempView[i])
                    }
                  }
                  this.loading=false
                }
              }
            })
        }
        else if (this.editBookUse===5){
          //是装配作业指导书的视频
          //对视频列表中的信息进行整合
          const index = this.videoList.findIndex(item => item.name === file.name);
          this.videoList.splice(index,1)
          //重新组合作业指导书的文本内容。
          //组合数据
          //向总数据中进行组合
          let temp=_.cloneDeep(this.workBook)
          //把新的图片字符串赋值
          temp[this.editBookScope.$index].videoList=this.editBookScope.row.videoList.replace(file.name+'|*|','')
          //判断一下，是不是删除后为空了，如果是，就设置为undefined
          if (temp[this.editBookScope.$index].videoList===''){
            temp[this.editBookScope.$index].videoList='undefined|*|'
          }
          //组合成为作业指导书的文本数据，用的方法是，先把每一条的数据组合起来。
          let strTemp=''//组合的临时变量,用在向后端保存数据的变量
          for (let i = 0; i < temp.length; i++) {
            //组合自己每一条的变量
            let itemStr=temp[i].work+'|%|'+temp[i].problem+'|%|'+temp[i].inspect+'|%|'+temp[i].spendTime
                +'|%|'+temp[i].controlPlan+'|%|'+temp[i].toll+'|%|'+temp[i].accessories+'|%|'+temp[i].device
                +'|%|'+temp[i].pictureList+'|%|'+temp[i].videoList+'|%|'
            strTemp=strTemp+itemStr+'|-|'
          }
          // 发送请求，执行删除文件，发送的是这一行的id，记录图片地址的字符串，以及需要修改的字段，为了减少后端的写的代码，重新返回新的文件名的序列内容，并且更新。
          this.loading=true
          this.$request.post('/operateGuideBookPictureRemove',{
            id:this.tableDataScope.row.id,
            fieldName:'workBook',
            filedVal:strTemp,
            pictureName:file.name
          }).
          then(result=>{
            if (result.code === 401) {
              this.$router.push('UserLogin')
              alert("您未登录，请登录")
            }
            else {
              if (result.data==='删除文件时出错'){
                alert("删除文件出错，请联系管理员")
              }
              else {
                //修改列表中的数据
                //修改主表中的数据和记录的保存数据
                this.tableData[this.tableDataScope.$index].workBook=result.data
                this.tableDataScope.row.workBook=result.data
                //组合走马灯的视频
                //修改作业指导书列表中的内容
                this.workBook[this.editBookScope.$index].videoList=temp[this.editBookScope.$index].videoList
                if (this.workBook[this.editBookScope.$index].videoList.includes('undefined')){
                  this.itemViewVideo=[]
                }
                else {
                  let pictureTemp=this.workBook[this.editBookScope.$index].videoList.split('|*|')
                  this.itemViewVideo=[]
                  for (let i = 0; i < pictureTemp.length-1; i++) {
                    let temp=filepath+pictureTemp[i]
                    this.itemViewVideo.push(temp)
                  }
                }
                this.loading=false
              }
            }
          })
        }

    },
    //照片\视频移除的函数(零部件列表中的）
    handleRemovePart(file) {
        //是装配作业指导书中的图片
        //对图片列表中的信息进行整合
        const index = this.PictureList.findIndex(item => item.name === file.name);
        this.PictureList.splice(index,1)
        //重新组合作业指导书的文本内容。
        //组合数据
        //向总数据中进行组合
        let temp=_.cloneDeep(this.partsListData)
        //把新的图片字符串赋值
        temp[this.partsListScope.$index].imageList=this.partsListScope.row.imageList.replace(file.name+'|*|','')
        //判断一下，是不是删除后为空了，如果是，就设置为undefined
        if (temp[this.partsListScope.$index].imageList===''){
          temp[this.partsListScope.$index].imageList='undefined|*|'
        }
        //组合成为作业指导书的文本数据，用的方法是，先把每一条的数据组合起来。
        let strTemp=''//组合的临时变量,用在向后端保存数据的变量
        for (let i = 0; i < temp.length; i++) {
          //组合自己每一条的变量
          let itemStr=temp[i].mapId+'|%|'+temp[i].stepNum+'|%|'+temp[i].partId+'|%|'+temp[i].partName
              +'|%|'+temp[i].partNum+'|%|'+temp[i].special+'|%|'+temp[i].endDate+'|%|'+temp[i].endName
              +'|%|'+temp[i].imageList+'|%|'+temp[i].reserve1+'|%|'+temp[i].reserve2+'|%|'+temp[i].reserve3+'|%|'
          strTemp=strTemp+itemStr+'|-|'
        }
        this.loading=true
        // 发送请求，执行删除文件，发送的是这一行的id，记录图片地址的字符串，以及需要修改的字段，为了减少后端的写的代码，重新返回新的文件名的序列内容，并且更新。
        this.$request.post('/operateGuideBookPictureRemove',{
          id:this.tableDataScope.row.id,
          fieldName:'partsList',
          filedVal:strTemp,
          pictureName:file.name
        }).
        then(result=>{
          if (result.code === 401) {
            this.$router.push('UserLogin')
            alert("您未登录，请登录")
          }
          else {
            if (result.data==='删除文件时出错'){
              alert("删除文件出错，请联系管理员")
            }else {
              //修改列表中的数据
              //修改主表中的数据和记录的保存数据
              this.tableData[this.tableDataScope.$index].partsList=result.data
              this.tableDataScope.row.partsList=result.data
              //组合走马灯的照片
              if (temp[this.partsListScope.$index].imageList.includes('undefined')){
                this.itemView=[]
              }
              else {
                this.itemView=[]
                let tempView=temp[this.partsListScope.$index].imageList.split('|*|')
                for (let i = 0; i < tempView.length-1; i++) {
                  this.itemView.push(filepath+tempView[i])
                }
              }
              this.loading=false
            }
          }
        })


    },
    // 辅助函数：将Base64编码的字符串转换为Blob对象
    dataURItoBlob(dataURI) {
      // 分离出头部信息,得到数据部分
      let byteString;
      if (dataURI.split(',')[0].indexOf('base64') >= 0)
        byteString = atob(dataURI.split(',')[1]);
      else
        byteString = unescape(dataURI.split(',')[1]);

      // 写入数组缓冲区
      let mimeString = dataURI.split(',')[0].split(':')[1].split(';')[0];
      let ia = new Uint8Array(byteString.length);
      for (let i = 0; i < byteString.length; i++) {
        ia[i] = byteString.charCodeAt(i);
      }
      return new Blob([ia], {type:mimeString});
    },
    // 辅助函数：触发Blob对象的下载
    downloadBlob(blob, fileName) {
      let link = document.createElement('a');
      link.href = window.URL.createObjectURL(blob);
      link.download = fileName;
      link.click();
      window.URL.revokeObjectURL(link.href);
    },
    //用户点击的是看图片还是看视频，进行元素的切换
    videoAndImage(doe){
      if (doe===1){
        // 用户要看图像
        this.editVideoAndImageUse=1;
        this.videoAndImage1='#0269fa'
        this.videoAndImageColor1='white'

        this.videoAndImage2='white'
        this.videoAndImageColor2=''
      }
      else if (doe===2){
        // 用户要看视频
        this.editVideoAndImageUse=2;
        this.videoAndImage2='#0269fa'
        this.videoAndImageColor2='white'

        this.videoAndImage1='white'
        this.videoAndImageColor1=''
      }
    },
    //用户点击的是看作业指导书中的哪个数据，表头的上面的列表切换。
    workBookHeard(doe){
      this.workBookHeardUse=doe
      //图片、视频展示清空
      this.itemView=[]
      this.itemViewVideo=[]
      if (doe===1){
        this.workBookHeard1='#0269fa'
        this.workBookHeardColour1='white'

        this.workBookHeard2=''
        this.workBookHeardColour2=''

        this.workBookHeard3=''
        this.workBookHeardColour3=''

        this.workBookHeard4=''
        this.workBookHeardColour4=''

        this.workBookHeard5=''
        this.workBookHeardColour5=''
      }
      else if (doe===2){
        this.workBookHeard1=''
        this.workBookHeardColour1=''

        this.workBookHeard2='#0269fa'
        this.workBookHeardColour2='white'

        this.workBookHeard3=''
        this.workBookHeardColour3=''

        this.workBookHeard4=''
        this.workBookHeardColour4=''

        this.workBookHeard5=''
        this.workBookHeardColour5=''
      }
      else if (doe===3){
        this.workBookHeard1=''
        this.workBookHeardColour1=''

        this.workBookHeard2=''
        this.workBookHeardColour2=''

        this.workBookHeard3='#0269fa'
        this.workBookHeardColour3='white'

        this.workBookHeard4=''
        this.workBookHeardColour4=''

        this.workBookHeard5=''
        this.workBookHeardColour5=''
      }
      //显示工时直方图
      else if (doe===4){
        this.workBookHeard1=''
        this.workBookHeardColour1=''

        this.workBookHeard2=''
        this.workBookHeardColour2=''

        this.workBookHeard3=''
        this.workBookHeardColour3=''

        this.workBookHeard4='#0269fa'
        this.workBookHeardColour4='white'

        this.workBookHeard5=''
        this.workBookHeardColour5=''

      }
      //显示合格人员明细
      else if (doe===5){
        this.workBookHeard1=''
        this.workBookHeardColour1=''

        this.workBookHeard2=''
        this.workBookHeardColour2=''

        this.workBookHeard3=''
        this.workBookHeardColour3=''

        this.workBookHeard4=''
        this.workBookHeardColour4=''

        this.workBookHeard5='#0269fa'
        this.workBookHeardColour5='white'
      }
    },

    //对作业指导书行单击的时候展开栏的时候触发的函数，调动展开的内容展示,主要是调动控制计划。
    workBookRowClick(row){
      if (!this.editBookScope) {
        this.$set(this, 'editBookScope', {}); // 先初始化
      }
      this.editBookScope.row = row;
      //去后端查询控制计划关联的内容
      if (row.controlPlan!=='-1'){
        //发送到后端进行查询
        this.$request.post('/inquiryControlPlanAssociationByOperateGuideBook',row.controlPlan)
            .then(result=>{
          if (result.code === 401) {
            this.$router.push('UserLogin')
            alert("您未登录，请登录")
          }
          else {
            this.isControlPlanLoad=false
            this.controlPlanData=result.data
            this.isControlPlanLoad=true
          }
        })
      }
      else {
        this.controlPlanData=[]
      }
    },
    //对控制计划部分多选的时候，产生的变化。
    controlPlanSelectionChange(val){
      this.controlPlanSelection = val;
      //对作业指导书中控制计划中的内容进行组合。
    },
    loadSelect(){
      //看是不是前期已经有关联项目
      if (this.editBookScope.row.controlPlan!=='-1'){
        //分割成数组，包含了控制计划中的id关联信息
        const controlTemp=this.editBookScope.row.controlPlan.split('|*|')
        //记录找到的控制计划的列表
        let controlList=[]
        for (let i = 0; i < controlTemp.length-1; i++) {
          const index = this.tableDataControl.findIndex(item => item.id ===Number(controlTemp[i]))
          console.log(index)
          if (index!==-1){
            controlList.push(this.tableDataControl[index])
          }
        }
        //把已经选择项显示在数据列表上
        this.toggleSelection(controlList)
      }
    },
    //对控制计划部分，回填已经选择的项目的函数
    toggleSelection(rows) {
      if (rows) {
        rows.forEach(row => {
          this.$refs.multipleTable.toggleRowSelection(row);
        });
      } else {
        this.$refs.multipleTable.clearSelection();
      }
    },
    //点击编辑零部件明细：1.编辑，2.向下插入；3.删除；4：图片；5：视频
    editPartsList(doe,scope){
      this.partsListDoe=doe
      this.partsListScope=scope
      //点击弹窗
      //是编辑
      if (doe===1){
        //数据赋值
        this.partsListFrom=_.cloneDeep(scope.row)
        this.partsListDialog=true
      }
      //是向下插入
      else if (doe===2){
        //数据初始化
        this.partsListFrom={
          // 图示代码
          mapId:'',
          // 工步号
          stepNum:'',
          // 零部件编号
          partId:'',
          // 零部件名称
          partName:'',
          // 数量
          partNum:'',
          // 特殊特性
          special:'',
          // 最后编辑时间
          endDate:'',
          //最后编辑人
          endName: '',
          // 图片列表
          imageList:'',
          // 预留
          reserve1:'',
          // 预留
          reserve2:'',
          // 预留
          reserve3:'',
        }
        this.titleUse='您正在向下插入一条零件信息'
        this.partsListDialog=true
      }
      //是删除
      else if (doe===3){
        //数据赋值
        this.partsListFrom=_.cloneDeep(scope.row)
        this.titleUse='您正在删除本条数据'
        this.partsListDialog=true
      }
      //是上传图片
      else if (doe===4){
        this.titleUse='上传图片（零部件部分）'
        //组合照片的数据
        if (this.partsListScope.row.imageList.includes('undefined')){
          //没有图片信息
          this.PictureList = []
        }
        else {
          this.PictureList = []
          const temp1 = this.partsListScope.row.imageList.split('|*|')
          for (let i = 0; i < temp1.length - 1; i++) {
            let temp2 = {
              name: temp1[i],
              percentage: 0,
              raw: File,
              size: 0,
              status: null,
              uid: null,
              url: filepath + temp1[i]
            }
            this.PictureList.push(temp2)
          }
        }
        this.fileType='image/jpeg, image/png'
        this.dialogPicturePart=true
      }
      // 是新建
      else if (doe===5){
        if (this.treeNode===null){
          alert('请选择工序')
          return
        }
        else if (this.tableDataScope===null){
          alert('请选择作业指导书')
          return;
        }
        //数据初始化
        this.partsListFrom={
          // 图示代码
          mapId:'',
          // 工步号
          stepNum:'',
          // 零部件编号
          partId:'',
          // 零部件名称
          partName:'',
          // 数量
          partNum:'',
          // 特殊特性
          special:'',
          // 最后编辑时间
          endDate:'',
          //最后编辑人
          endName: '',
          // 图片列表
          imageList:'',
          // 预留
          reserve1:'',
          // 预留
          reserve2:'',
          // 预留
          reserve3:'',
        }
        this.titleUse='您正在新建一条零件信息'
        this.partsListDialog=true
      }
    },
    //点击编辑零部件明细弹窗的确定按钮，保存数据
    partsListEditClick(){
      //数据校验
      if (this.partsListFrom.partName===''){
        alert("请填写零部件名称")
        return
      }
      else if (this.partsListFrom.partNum<=0){
        alert('请输入正确的数量')
        return;
      }

      //根据不同情况组合数据
      let str=''
      //组合最后编辑时间
      const now = new Date();
      const year = now.getFullYear();
      const month = String(now.getMonth() + 1).padStart(2, '0'); // 月份是从0开始的
      const day = String(now.getDate()).padStart(2, '0');
      const hours = String(now.getHours()).padStart(2, '0');
      const minutes = String(now.getMinutes()).padStart(2, '0');
      const seconds = String(now.getSeconds()).padStart(2, '0');
      this.partsListFrom.editTime=`${year}-${month}-${day} ${hours}:${minutes}:${seconds}`
      //组合最后编辑人
      this.partsListFrom.endName=this.useName

      //是新建
      if (this.partsListDoe===5){
        //直接组合
        //给图片赋值为空
        this.partsListFrom.imageList='undefined|*|'
        str=this.partsListFrom.mapId+'|%|'+
            this.partsListFrom.stepNum+'|%|'+
            this.partsListFrom.partId+'|%|'+
            this.partsListFrom.partName+'|%|'+
            this.partsListFrom.partNum+'|%|'+
            this.partsListFrom.special+'|%|'+
            this.partsListFrom.endDate+'|%|'+
            this.partsListFrom.endName+'|%|'+
            this.partsListFrom.imageList+'|%|'+
            this.partsListFrom.reserve1+'|%|'+
            this.partsListFrom.reserve2+'|%|'+
            this.partsListFrom.reserve3+'|-|'
      }
      //是编辑
      else if (this.partsListDoe===1){
        //组合数据
        let strTemp=this.partsListFrom.mapId+'|%|'+
            this.partsListFrom.stepNum+'|%|'+
            this.partsListFrom.partId+'|%|'+
            this.partsListFrom.partName+'|%|'+
            this.partsListFrom.partNum+'|%|'+
            this.partsListFrom.special+'|%|'+
            this.partsListFrom.endDate+'|%|'+
            this.partsListFrom.endName+'|%|'+
            this.partsListFrom.imageList+'|%|'+
            this.partsListFrom.reserve1+'|%|'+
            this.partsListFrom.reserve2+'|%|'+
            this.partsListFrom.reserve3
        //直接对总表进行操作
        let partList=this.tableData[this.tableDataScope.$index].partsList.split('|-|')
        //更换数据
        partList[this.partsListScope.$index]=strTemp
        //组合大数据
        str=''
        for (let i = 0; i < partList.length-1; i++) {
          str=str+partList[i]+'|-|'
        }
      }
      //是向下插入
      else if (this.partsListDoe===2){
        //组合数据
        this.partsListFrom.imageList='undefined|*|'
        let strTemp=this.partsListFrom.mapId+'|%|'+
            this.partsListFrom.stepNum+'|%|'+
            this.partsListFrom.partId+'|%|'+
            this.partsListFrom.partName+'|%|'+
            this.partsListFrom.partNum+'|%|'+
            this.partsListFrom.special+'|%|'+
            this.partsListFrom.endDate+'|%|'+
            this.partsListFrom.endName+'|%|'+
            this.partsListFrom.imageList+'|%|'+
            this.partsListFrom.reserve1+'|%|'+
            this.partsListFrom.reserve2+'|%|'+
            this.partsListFrom.reserve3
        //直接对总表进行操作
        let partList=this.tableData[this.tableDataScope.$index].partsList.split('|-|')
        //插入数据
        partList.splice(this.partsListScope.$index+1,0,strTemp)
        //组合大数据
        str=''
        for (let i = 0; i < partList.length-1; i++) {
          str=str+partList[i]+'|-|'
        }
      }
      //是删除本行
      else if (this.partsListDoe===3){
        //直接对总表进行操作
        let partList=this.tableData[this.tableDataScope.$index].partsList.split('|-|')
        //插入数据
        partList.splice(this.partsListScope.$index,1)
        //组合大数据
        str=''
        for (let i = 0; i < partList.length-1; i++) {
          str=str+partList[i]+'|-|'
        }
      }

      if (str===''){
        alert("数据出现异常，请联系管理员")
      }
      else {
        //向后端发送请求
        this.$request.post('operateGuideBookOneFiledById',{
          id:this.tableDataScope.row.id,
          filedName:'partsList',
          filedVal:str,
        })
            .then(result=>{
          if (result.code === 401) {
            this.$router.push('UserLogin')
            alert("您未登录，请登录")
          }else {
            //修改大表数据
            this.tableData[this.tableDataScope.$index].partsList=str
            //修改临时数据的内容
            this.tableDataScope.row.partsList=str
            this.tableDataTemp.partsList=str
            //新组合零部件明细
            this.partsListData=[]
            let partsTemp=str.split('|-|')
            for (let i = 0; i < partsTemp.length-1; i++) {
              let partsItem=partsTemp[i].split('|%|')
              let temp={
                // 图示代码
                mapId:partsItem[0],
                // 工步号
                stepNum:partsItem[1],
                // 零部件编号
                partId:partsItem[2],
                // 零部件名称
                partName:partsItem[3],
                // 数量
                partNum:partsItem[4],
                // 特殊特性
                special:partsItem[5],
                // 最后编辑时间
                endDate:partsItem[6],
                // 最后编辑人
                endName: partsItem[7],
                // 图片列表
                imageList:partsItem[8],
                // 预留
                reserve1:partsItem[9],
                // 预留
                reserve2:partsItem[10],
                // 预留
                reserve3:partsItem[11],
              }
              this.partsListData.push(temp)
            }
            this.partsListDialog=false
          }
        })

      }
    },
    //零部件的行上单击
    partsListClick(row){
      //组合图片数据
      //组合走马灯的照片
      if (row.imageList.includes('undefined')){
        this.itemView=[]
      }
      else {
        let pictureTemp=row.imageList.split('|*|')
        this.itemView=[]
        for (let i = 0; i < pictureTemp.length-1; i++) {
          let temp=filepath+pictureTemp[i]
          this.itemView.push(temp)
        }
      }
    },
    //编审批的函数
    ratifyClick(doe){
      //是审核
      if (doe===1){
        if (this.tableDataTemp.examineUse.includes(this.useName)){
          //修改数据
         let str=this.useName+'/已审批'
          //向后端传递数据，修改一个字段
          //向后端发送请求
          this.$request.post('operateGuideBookOneFiledById',{
            id:this.tableDataScope.row.id,
            filedName:'examineUse',
            filedVal:str,
          })
              .then(result=>{
                if (result.code === 401) {
                  this.$router.push('UserLogin')
                  alert("您未登录，请登录")
                }else {
                  //修改大表数据
                  this.tableData[this.tableDataScope.$index].examineUse=str
                  //修改临时数据的内容
                  this.tableDataScope.row.examineUse=str
                  this.tableDataTemp.examineUse=str
                  alert("已经审批完成")
                }
              })
        }
        else {
          alert("您不可以审批")
        }
      }
      //是批准
      else if (doe===2){
        if (this.tableDataTemp.ratifyUse.includes(this.useName)){
          //修改数据
          let str=this.useName+'/已审批'
          //向后端传递数据，修改一个字段
          //向后端发送请求
          this.$request.post('operateGuideBookOneFiledById',{
            id:this.tableDataScope.row.id,
            filedName:'ratifyUse',
            filedVal:str,
          })
              .then(result=>{
                if (result.code === 401) {
                  this.$router.push('UserLogin')
                  alert("您未登录，请登录")
                }else {
                  //修改大表数据
                  this.tableData[this.tableDataScope.$index].ratifyUse=str
                  //修改临时数据的内容
                  this.tableDataScope.row.ratifyUse=str
                  this.tableDataTemp.ratifyUse=str
                  alert("已经审批完成")
                }
              })
        }
        else {
          alert("您不可以审批")
        }
      }
      //是会签
      else if (doe===3){
        if (this.tableDataTemp.countersignUse.includes(this.useName)){
          //修改数据
          let str=this.useName+'/已审批'
          //向后端传递数据，修改一个字段
          //向后端发送请求
          this.$request.post('operateGuideBookOneFiledById',{
            id:this.tableDataScope.row.id,
            filedName:'countersignUse',
            filedVal:str,
          })
              .then(result=>{
                if (result.code === 401) {
                  this.$router.push('UserLogin')
                  alert("您未登录，请登录")
                }else {
                  //修改大表数据
                  this.tableData[this.tableDataScope.$index].countersignUse=str
                  //修改临时数据的内容
                  this.tableDataScope.row.countersignUse=str
                  this.tableDataTemp.countersignUse=str
                  alert("已经审批完成")
                }
              })
        }
        else {
          alert("您不可以审批")
        }
      }
    },
    //画工时的直方图
    initChart() {
      // 组合数据
      let totalTime=0
      for (let i = 0; i < this.workBook.length; i++) {
        this.optionBor.xAxis[0].data[i] = i + 1;
        this.optionBor.series[0].data[i] = this.workBook[i].spendTime;
        totalTime += parseInt(this.workBook[i].spendTime, 10)
      }
      if (this.languageS==='chinese'){
        this.optionBor.title.text='时间分布图'
      }
      else if (this.languageS==='english'){
        this.optionBor.title.text='Time distribution chart'
      }
      else if (this.languageS==='russian'){
        this.optionBor.title.text='График распределения времени'
      }
      this.optionBor.title.subtext='总时长/Total time/Общее время：'+totalTime
      if (this.$refs.myChartBor) {
        // 初始化图表并设置选项
        this.chartUserBor = echarts.init(this.$refs.myChartBor);
        this.chartUserBor.setOption(this.optionBor);
      } else {
        console.error('DOM element not found for chart initialization');
      }
    },
    //点击编辑实现案例库：1.新增、2.编辑、3.删除、4.上传图片、5.上传视频、6.向下插入；
    caseUseShow(doe,scope){
      this.caseUseDoe=doe
      this.caseUseScope=scope
      //是新建/新增一条
      if (doe===1){
        if (this.tableDataScope===null){
          this.$message.error('您未选择工序，或本工序为空，请选择工序')
          return
        }
        //弹窗打开，就是一段文字的录入
        this.caseUseDialog=true
        this.titleUse='您正在新增一条失效案例库'
        this.caseUseData=[{
          id: '1',
          caseUse: '',
          editName: '',
          editDate: '',
          pictureList: '',
          videoList: '',
          reserve1: '',
          reserve2: '',
          reserve3: ''
        }]
      }
      //是编辑一条
      else if (doe===2){
        //把值赋给文本框
        this.inputTextCaseUse=_.cloneDeep(scope.row.caseUse)
        this.titleUse='您正在编辑本条失效信息'
        this.caseUseDialog=true
      }
      //是删除一个失效案例
      else if (doe===3){
        this.inputTextCaseUse=scope.row.caseUse
        this.titleUse='您正在删除本条失效案例'
        this.caseUseDialog=true
      }
      //是向下插入一条
      else if (doe===6){
        this.inputTextCaseUse=''
        this.titleUse='您正在向下插入一条失效案例'
        this.caseUseDialog=true
      }
    },
    //点击在《失效案例库》中的编辑窗口确定按钮
    caseUseEdit(){
      let str
      //新增一条实现案例（是本序没有，空白新增）如果以前有失效案例，这个新增按钮都没有,不会显示
      if (this.inputTextCaseUse===''  || this.inputTextCaseUse===undefined){
        this.$message.error('您未输入失效信息，请输入后点击确定')
        return
      }
      //是新增一条失效案例
      if (this.caseUseDoe===1){
        //组合数据
        //得到新输入的数据
        this.caseUseData[0].caseUse=this.inputTextCaseUse
        this.caseUseData[0].editName=this.useName
        this.caseUseData[0].editDate=this.nowDateStr()

      }
      //编辑一条失效案例
      else if (this.caseUseDoe===2){
        //组合新的数据
        this.caseUseData[this.caseUseScope.$index].caseUse=this.inputTextCaseUse
        this.caseUseData[this.caseUseScope.$index].editName=this.useName
        this.caseUseData[this.caseUseScope.$index].editDate=this.nowDateStr()

      }
      //是向删除一条失效案例
      else if (this.caseUseDoe===3){
        this.caseUseData.splice(this.caseUseScope.$index,1)
        console.log(this.caseUseData)
      }
      //向下插入一条信息
      else if (this.caseUseDoe===6){
        let temp={
          id: '-1',
            caseUse: this.inputTextCaseUse,
            editName: this.useName,
            editDate: this.nowDateStr(),
            pictureList: '',
            videoList: '',
            reserve1: '',
            reserve2: '',
            reserve3: ''
        }
        this.caseUseData.splice(this.caseUseScope.$index+1,0,temp)
      }

      // 获取对象的所有键，并过滤掉 'id' 键
      str = this.caseUseData.map(obj => {
        return Object.keys(obj)
            .filter(key => key !== 'id')  // 排除 id 键
            .map(key => obj[key])         // 获取每个键的值
            .join('|%|');                 // 使用 '|%|' 连接成字符串
      }).join('|-|');// 使用 '|-|' 连接每个对象的字符串

      //向后端发送请求，用的是修改一个字段的端口
      this.$request.post('operateGuideBookOneFiledById',{
        id:this.tableDataScope.row.id,
        filedName:'caseUse',
        filedVal:str,
      })
          .then(result=>{
            if (result.code === 401) {
              this.$router.push('UserLogin')
              alert("您未登录，请登录")
            }else {
              //修改大表数据
              this.tableData[this.tableDataScope.$index].caseUse=str
              //修改临时数据的内容
              this.tableDataScope.row.caseUse=str
              this.tableDataTemp.caseUse=str
              //新组合失效案例库
              //对失效案例库列表进行组合
              this.caseUseData=[]
              let caseUseTemp=this.tableData[this.tableDataScope.$index].caseUse.split('|-|')
              if (caseUseTemp.length===0){
                caseUseTemp.push(this.tableData[this.tableDataScope.$index].caseUse)
              }
              for (let i = 0; i < caseUseTemp.length; i++) {
                let caseUseItem=caseUseTemp[i].split('|%|')
                let temp={
                  id: i,
                  caseUse: caseUseItem[0],
                  editName: caseUseItem[1],
                  editDate: caseUseItem[2],
                  pictureList: caseUseItem[3],
                  videoList: caseUseItem[4],
                  reserve1: caseUseItem[5],
                  reserve2: caseUseItem[6],
                  reserve3: caseUseItem[7]
                }
                this.caseUseData.push(temp)
              }
              this.caseUseDialog=false
            }
          })
    },
    //辅助函数：对零部件信息进行调用,调用所有的信息
    inquiryProductListBaseComponentAll(){
      this.$request.post('/inquiryProductListBaseComponentAll').then(result=>{
        if (result.code === 401) {
          this.$router.push('UserLogin')
          alert("您未登录，请登录")
        } else {
          this.partsListOptions=[]
          for (let i = 0; i < result.data.length; i++) {
            let temp={
              label:result.data[i].cpxh+'/'+result.data[i].lbjmc_C+'/'+result.data[i].lbjmc_E+'/'+result.data[i].lbjmc_R+'/'+result.data[i].sccj,
              value:result.data[i].cpxh+'/'+result.data[i].lbjmc_C+'/'+result.data[i].lbjmc_E+'/'+result.data[i].lbjmc_R+'/'+result.data[i].sccj,
            }
            this.partsListOptions.push(temp)
          }
          // 最后，更新 productModelListOption 数组，消除重复项
          this.partsListOptions = [...new Set(this.partsListOptions.map(item => JSON.stringify(item)))]
              .map(itemString => JSON.parse(itemString));
        }
      })
    },
    //辅助函数：根据两个字符串类型的字段，查询分别等于某一值的数据(控制计划的表）
    async queryThreeFieldControlPlan(firstFieldName, firstFieldVal, secondFieldName, secondFieldVal, thirdFieldName, thirdFieldVal) {
      const result = await this.$request.post('/queryThreeFieldControlPlanControlPlanNew', {
        firstFieldName: firstFieldName,
        firstFieldVal: firstFieldVal,
        secondFieldName:secondFieldName,
        secondFieldVal:secondFieldVal,
        thirdFieldName:thirdFieldName,
        thirdFieldVal:thirdFieldVal,
      })
      if (result.code === 401) {
        // 未登录，跳转到登录页面并提示
        this.$router.push('UserLogin');
        alert("您未登录，请登录");
      } else {
        // 成功，直接返回 result.data
        return result.data;
      }
    },

    //初始化单个富文本
    initEditor(editorKey, refName, htmlVal) {
      // 销毁已有实例
      if (this[editorKey]) {
        this[editorKey].destroy();
        this[editorKey] = null;
      }

      const container = this.$refs[refName];
      if (!container) return;

      // 创建新实例
      this[editorKey] = new E(container);

      // 配置菜单
      this[editorKey].config.menus = [
        'head',
        'bold',
        'italic',
        'underline',
        'strikeThrough',
        'foreColor',
        'backColor',
        'list',
        'justify',
        'table'
      ];

      this[editorKey].create();
      this[editorKey].txt.html(htmlVal)
    },
    // 获取所有编辑器内容
    getEditorContents() {
      return {
        points: {
          chinese: this.pointsChineseEditor?.txt.html() || '',
          english: this.pointsEnglishEditor?.txt.html() || '',
          russian: this.pointsRussianEditor?.txt.html() || ''
        },
        qualityCheck: {
          chinese: this.qualityCheckChineseEditor?.txt.html() || '',
          english: this.qualityCheckEnglishEditor?.txt.html() || '',
          russian: this.qualityCheckRussianEditor?.txt.html() || ''
        }
      };
    },
    // 销毁所有编辑器
    destroyAllEditors() {
      const editors = [
        'pointsChineseEditor',
        'pointsEnglishEditor',
        'pointsRussianEditor',
        'qualityCheckChineseEditor',
        'qualityCheckEnglishEditor',
        'qualityCheckRussianEditor'
      ];

      editors.forEach(editorKey => {
        if (this[editorKey]) {
          this[editorKey].destroy();
          this[editorKey] = null;
        }
      });
    },
    //上传头像用到的函数
    handleAvatarSuccess(file) {
      this.operatorListImageUrl = URL.createObjectURL(file.raw);
      this.operatorListFile=file
    },
    beforeAvatarUpload(file) {
      // 允许的MIME类型列表
      const allowedTypes = ['image/jpeg', 'image/png', 'image/jpg'];

      // 修正后的类型检查（使用数组includes）
      const isAllowedType = allowedTypes.includes(file.type);

      // 大小检查保持不变
      const isLt2M = file.size / 1024 / 1024 < 2;

      if (!isAllowedType) {
        this.$message.error('只能上传 JPG/PNG 格式的图片!');
      }

      return isAllowedType && isLt2M;
    }
  },
  // 组件销毁前清理
  beforeDestroy() {
    this.destroyAllEditors();
  },
  watch: {
    filterText(val) {
      this.$refs.tree.filter(val);
    },
    workBookHeardUse(newVal) {
      this.$nextTick(() => {
        if (newVal === 4 && !this.chartUserBor) {
          this.initChart();
        } else if (newVal !== 4 && this.chartUserBor) {
          this.chartUserBor.dispose();
          this.chartUserBor = null;
        }
      });
    },
    //监听对话框关闭
    dialogVisibleText(newVal) {
      if (!newVal) {
        this.destroyAllEditors();
      }
    },
  },

  mounted() {
    //查询用户信息
    this.inquiry()
    this.workBook=[]
    this.partsListData=[]
    this.caseUseData=[]
    this.operatorList=[]
    this.inquiryProductListBaseComponentAll()
  }
}
</script>

<style scoped>
/* 主体左侧的工作步骤栏用到的数据包围的div的样式*/

.el-footer {
  background-color: #ffffff;
  color: #333;
  text-align: center;
  border-width: 3px; /* 设置边框宽度为3像素 */
  border-color: blue; /* 设置边框颜色为蓝色 */
  border-style: solid; /* 设置边框样式为实线 */
  padding: 10px; /* 添加内边距 */
  border-left-color: white;
  border-top: white;
}

.el-aside {
  background-color: #ffffff;
  color: #333;
  text-align: center;
  border-width: 3px; /* 设置边框宽度为3像素 */
  border-color: blue; /* 设置边框颜色为蓝色 */
  border-style: solid; /* 设置边框样式为实线 */
  padding: 10px; /* 添加内边距 */
  height: 89vh;
}

.el-main {
  color: #333;
  text-align: center;
  border-width: 3px; /* 设置边框宽度为3像素 */
  border-color: blue; /* 设置边框颜色为蓝色 */
  border-left-color: white;
  border-style: solid; /* 设置边框样式为实线 */
  padding: 10px; /* 添加内边距 */
}

body > .el-container {
  margin-bottom: 40px;
}

.el-container:nth-child(5) .el-aside,
.el-container:nth-child(6) .el-aside {
  line-height: 260px;
}

.el-container:nth-child(7) .el-aside {
  line-height: 320px;
}

.headMain{
  color: #ffffff; /* 设置字体颜色为红色 */
  font-size: 18px;
}
.center-text {
  /* 使用 margin-left 和 margin-right auto 来实现居中效果 */
  margin-left: auto;
  margin-right: auto;
  /* 注意：如果 header 内只有这两个元素，你可能不需要 margin-right: auto */
}
.editor-container {
  border: 1px solid #ccc;
  height: 342px;
  margin-top: 8px;
}
.editor-container .w-e-text-container {
  height: 100% !important;
}

/*自定义样式*/
.avatar-uploader :deep(.el-upload) {
  border: 1px dashed #d9d9d9 !important; /* 强制边框样式 */
  border-radius: 6px;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  width: 200px;  /* 强制保证容器尺寸 */
  height: 200px;
}

/* 增强悬停效果 */
.avatar-uploader :deep(.el-upload:hover) {
  border-color: #409EFF !important;
}

/* 防止全局蓝色边框继承 */
.avatar-uploader :deep(.el-upload) {
  border-top-color: #d9d9d9 !important;
  border-left-color: #d9d9d9 !important;
}

/* 上传图片的样式 */
.avatar-uploader-icon {
  font-size: 28px;
  color: #8c939d;
  width: 200px;
  height: 200px;
  line-height: 200px;
  text-align: center;
}
.avatar {
  width: 200px;
  height: 200px;
  display: block;
}

/* 修改文本框中俄语的字体 */
/* 穿透Element UI组件样式 */
::v-deep .russian-input .el-textarea__inner {
  /* 推荐俄语字体组合（西里尔字母优化） */
  font-family: "Segoe UI", "Roboto", "Arial", sans-serif;

  /* 行高优化（俄语推荐1.3-1.5） */
  line-height: 1.4 !important;

  /* 字体大小调整（可选） */
  font-size: 14px;

  /* 字母间距微调 */
  letter-spacing: 0.02em;
}

</style>